I’m having the worst time trying to figure out how to do this. I currently need Canvas - Screen Space Camera set so that I can apply a bloom effect to my HUD. The problem is, when that mode is set, objects can occlude the UI which is very bad. I cant use overlay, because that doesn’t work with the image effects.
I’ve tried creating a separate camera to render just the UI, setting it to Clear Depth Only and setting it’s depth higher than the main camera, but as has been the case since Unity 3, this clears all image effects on the main camera. I can get bloom on the UI camera to work just fine, and it works in the scene from the main camera as well, but SSAO doesn’t work because it requires depth information from the main camera, not the UI camera.
Is there any way I can do this? Is there a way to force UI to draw on top of everything while in Screen Space Camera mode? I’ve been able to sort of achieve this effect with setting the shader to ZTest Always, but then that destroys the ability to do stencil masking, which I need for the circular minimap.
Here is the way I need the UI to look: