Search Unity

How to handle atomsphere

Discussion in '2D' started by Darkkingdom, Oct 26, 2019.

  1. Darkkingdom

    Darkkingdom

    Joined:
    Sep 2, 2014
    Posts:
    81
    Hey guys,

    we are working on a side scrolling 2D game.
    We try to achieve some nice depth in our background arts, so we need to take the atmosphere into account.
    So layers that are further away need to get gradually more blurred, less detailed and colored towards the atmosphere.
    (f.e. a blue sky in the background)

    To illustrate this: Here is a screenshot of Rayman.



    We are wondering what would be the best way to achieve this on the technical side.
    Would you take all of that into account while drawing the assets (maybe even with some non-destructive photoshop techniques) or draw them as if they are all on the same layer and
    "correct" the assets inside the engine afterwards.

    I see pro and cons for both ways, but would love to hear your thoughts about it. I am really confused.
     
  2. Antypodish

    Antypodish

    Joined:
    Apr 29, 2014
    Posts:
    10,778
    There are multiple options.
    Do 2D/3D assets, which represent further distance. Probably harder to maintain, but cheaper for game to run.
    Or having separate rendering layers, with possible post processing.
    Distance Fog.
    Custom shaders.
    Mix of these.
     
    eses and vakabaka like this.
  3. MisterSkitz

    MisterSkitz

    Joined:
    Sep 2, 2015
    Posts:
    833
    You can add a Halo to an object(s) in the back ground and set the amount of haze you want and even the color.

    https://docs.unity3d.com/Manual/class-Halo.html

    However, I don't know the extent of performance cost or whether it will work on specific mobile devices.
     
  4. Darkkingdom

    Darkkingdom

    Joined:
    Sep 2, 2014
    Posts:
    81
    Thank you both for your answers,
    we don’t have any plans to release our game to mobile, so it sounds like a mix oft the named techniques maybe the way to go for us.

    But I wonder how performance heavy those techniques really are.
    Maybe someone already worked on a similar project and can provide some insights?
    Either regarding performance or asset creation.
     
  5. Antypodish

    Antypodish

    Joined:
    Apr 29, 2014
    Posts:
    10,778
    Test it and profile it.
    There isn't defined answer, as things can be optimized in many ways. And from project to project could be completely different answer.
     
    MisterSkitz likes this.