Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Applying an image effect to just one camera

Discussion in 'Editor & General Support' started by Dudledok, Jun 23, 2015.

  1. Dudledok

    Dudledok

    Joined:
    Oct 24, 2013
    Posts:
    110
    I have two cameras in my scene, one for almost everything, and another for a single layer which will be part of the HUD.

    For the HUD I want to add the bloom effect, so I did on that camera, but despite that camera's culling mask only showing the one layer which I applied to just a couple of GameObjects, everything has a bloom applied.

    This seems like odd behaviour to me and so how do I go about just having a bloom on the HUD elements?
     
  2. angrypenguin

    angrypenguin

    Joined:
    Dec 29, 2011
    Posts:
    15,494
    How is your HUD camera configured? The first idea that jumps out to me is that you're passing a render texture from one to the other, so the whole thing is being passed to the image effect instead of just the HUD elements.
     
  3. Dudledok

    Dudledok

    Joined:
    Oct 24, 2013
    Posts:
    110
    Normal Camera:
    Clear flags - Skybox
    Culling Mask - Everything apart from the HUD
    Projection - Perspective
    FoV - 60
    Clippin - Near: 0.3, Far: 1000
    Viewport - X: 0, Y: 0, W: 1, H: 1
    Depth - 0
    Target Texture - None
    Occlusion Culling - Yes
    HDR - No

    HUD Camera:
    Clear flags - Depth Only
    Culling Mask - Only the HUD
    Projection - Perspective
    FoV - 60
    Clippin - Near: 0.3, Far: 500
    Viewport - X: 0, Y: 0, W: 1, H: 1
    Depth - 1
    Target Texture - None
    Occlusion Culling - Yes
    HDR - No
     
  4. webik150

    webik150

    Joined:
    Mar 23, 2013
    Posts:
    57
    Sorry for the necro, but have you solved this @Dudledok ?
    I'm facing the same problem. I have 3 cameras, one for almost everything and two for backgrounds (in a 2D game).
    I would like to apply bloom to the camera in the middle, but it applies to the lowest as well.
     
  5. Dudledok

    Dudledok

    Joined:
    Oct 24, 2013
    Posts:
    110
    Does it apply to just two of the three? If so try and find the difference between those two and the third. No I didn't solve it.
     
  6. webik150

    webik150

    Joined:
    Mar 23, 2013
    Posts:
    57
    If I add bloom to the second camera, it applies to second and first (depth 0 and 1).
    Since the second camera renders stars I've gone around it, by switching it with the depth 0 camera... Sort of hard to describe it.

    I of course caused many other problems, but I'll hopefully solve those.
     
  7. Oshigawa

    Oshigawa

    Joined:
    Jan 26, 2016
    Posts:
    362
    Sorry for necroing too, i've got the same problem, any ideas on this one? Should i fiddle around with camera depths?

    Edit: Nope, that doesn't work too.
     
    Last edited: Oct 24, 2017