Archive 17/01/2023.

Shadows do not render on more than one Render Texture using HWDepth

SeanV

Hello, I’m working on integrating OpenVR into Urho3D, but I’ve noticed a problem when using more than one Render Texture with hardware depth.

Only the last texture to have SetSize() called on it will have shadows. The other texture will have no shadows rendered – yet if the camera itself is in shadow then the entire scene will be in shadow.

This can be verified by altering the RenderToTexture sample to have two cameras and two screens. The first render texture will only have shadows if the second render texture is out of view. I can provide this code if necessary!

This bug only occurs when using render paths that make use of HWDepth, like PBRDeferredHWDepth. Notably, the bug does not come up when using ForwardHWDepth.

cadaver

Recommend to make a Github issue, so that this isn’t forgotten.

SeanV

Thanks, I’ll do that. I was hoping I was just doing something wrong!