#HDRP camera-stacking / virtual Monitor

1 messages · Page 1 of 1 (latest)

halcyon sparrow
#

Hello world. I want to create a small mech game. The pilot sits in the cockpit and can see the environment and UI via a screen.
To create this in unity I´m using 3 cameras:

  • 1st camera renders only the inner cockpit
  • 2nd camera renders only the environment -> output: render texture)
  • 3rd camera renders only the UI (crosshair, speed, ammo, etc) -> output: render texture

So the two render textures are merged in a shader and finally the resulting texture is used for the screen in the cockpit.

Unfortunately it´s not really working. My current setup won´t render only the existing UI elements on a blank background (alpha = 0). So I can´t cutout the "UI texture" on the "environment texture" OR I just can´t blend them....

edit: I´m using dark/black UI elements. So I can´t use a solid black background in the "UI camera´s" background type as it would "ignore" my dark UI elements (although it would solve my problem in a certain way)

I´m really confused. I hope you get the problem and my goal.

Thanks for your time and help......

using:
Unity 6000.2.10f1 ; HDRP 17
(Nearly fresh project)

echo spade
#

Camera stacking is not supported in HDRP (or rather, extremely unoptimized).

I know there's another way to do this, but I haven't had to dig into this yet.

mystic eagle
halcyon sparrow
halcyon sparrow
# mystic eagle What was your solution?

oh, sry the very late answer.
Two cameras. One renders the interior, the other the exterior with an world space UI which scales depending on the camera´s FOV.
However I have new issues with this setup

mystic eagle
#

With custom passes (and help of light layers) you might be able to render the world behind the cockpit separately

halcyon sparrow