Search Unity

Lens Flare and layers

Discussion in 'Editor & General Support' started by holmeren, Jul 27, 2008.

  1. holmeren

    holmeren

    Joined:
    Dec 12, 2006
    Posts:
    300
    Hey
    I have a scene with a lot of "Lens Flares" and Im have put them on a separate layer for a Flare Camera.
    All my Lens Flares have "layer" Flare and my Flare Cam is only rendering this "Flare Layer"
    I also have a player cam rendering the rest ;)
    But I cant seem to get the Flare cam to work... all my flares are rendered even if I turn the Flare Cam of, the deal is Flare Cam has a much smaller Clipping Plane distance than the Player Cam.
    Is it so that Lens Flare is post processed on top of it all and therefore ignores layers?

    Cheers :oops:
     
  2. mia

    mia

    Joined:
    Dec 31, 2007
    Posts:
    83
    it depends on how you are compositing your scene but sounds like you may need to adjust the 'Clear Flags' on your various cameras as well as the 'Depth' order. i usually set my flare cam to 'Solid Color' (as well as place it on it's own layer), then my Main cam i set to 'Depth Only' unless you're using a skybox otherwise that gets set on your background cam. Actual 'Depth' values depend on how you want the final scene to appear so may have to experiment with that to find what works best.
     
  3. holmeren

    holmeren

    Joined:
    Dec 12, 2006
    Posts:
    300
    Hi Mia
    Ill forward this to the office ;)
    Im off this week on summer holiday hehehe....
    Thanks