Hi, we switched to URP and have multiple scenes with multiple cameras, everything is 2D UI.
The base scene has its own Base Camera. The possible additive overlay scenes have their own base camera. But the overlays overwrite the underlaying cameras rendered image. I checked the frame debugger and they are both drawn, but the transparency of the overlay scene gets opaque while rendering.
Hope someone can help. It did work at one point, but now we changed quite a few things around, how we want to render our overlays and adding multiple cameras killed the pipeline I guess. >.<
Okay, I just found out, that the Renderer we use (2D Renderer (Experimental)) caused the Stack warning above. I tried out setting the stack when in play mode. This worked, but we would need to write a algorithm that sets the cameras to overlay other cameras and stuff like that.
Thats obviously not what I want.
The cameras should just draw over another, depending on the scene stack and / or the camera Priority setting. That must be automatic, did I miss the setting?
PS: And of course an other problem. We can’t test Overlay cameras in their standalone scene for development. So I really want Base cameras everywhere. The frame debugger showed no optimization while using the camera stack anyway.
Ah, forgot that. We are using Unity 2019.4.1, so URP version is 7.3.1 accordingly.
We are still not sure if we need the 2D Experimental renderer, still in the testing phase.
But anyway: If we are using URP, we have to keep track of all our cameras and can’t use depth anymore for unity to figure out what to draw?
As I mentioned, in the frame debugger I couldn’t see any improvement either. since half of the overlayed scene was drawn anyway, before the overlay camera was drawn above that. So what’s the point? ^^
Well, yes and no. We went with a base camera from our initialisation scene and a custom scene manager that adds and removes overlay cameras.
To test our scenes we have a “Scene Tester” that has a base camera attached and the scenes overlay camera added to its stack. And if the app is regularly started these testers get destroyed.