UnityURPUnlitScreenSpaceDecalShader icon indicating copy to clipboard operation
UnityURPUnlitScreenSpaceDecalShader copied to clipboard

Issues in Virtual Reality

Open alexis-dupuis opened this issue 5 years ago • 8 comments

Hi ColinLeug-NiloCat,

First of all thank you kindly for providing a solution for decal projectors in URP, as it's quite an important feature yet missing in forward renderers.

I've been putting a lot of work on a decal system using your shader, until I realized it doesn't work in VR. I saw people reporting this issue on another decal projector shader (now depreciated), and the author apparently managed to make it usable in VR.

Would you know if it's feasible with your shader too?

alexis-dupuis avatar Jul 13 '20 19:07 alexis-dupuis

Sorry I don’t have any VR experience before so I am not sure what to do, and I don’t have a VR device to validate the fix.

I believe Lux URP essentials shader in the asset-store have the decal Shader that support VR

ColinLeung-NiloCat avatar Jul 14 '20 03:07 ColinLeung-NiloCat

It actually works on VR (Oculus Quest 2, Unity 2020.1.12f1, URP with Depth Texture activated) out of the box, at least for me. The oculus texture plastered on the wall is the decal from Colin's shader.

image

edit: though I noticed that the decal is not rendered every other frame while moving, only for one eye (right in my case), no idea why.

RamonBeast avatar Nov 12 '20 15:11 RamonBeast

Same problem for me, but it can be fixed in one step ly73iTnDEc Switch rendering mode to Multi Pass (Hope its not only oculus feature). But maybe you will have a decal moving delay in VR.

mypaxa00 avatar Jan 18 '21 15:01 mypaxa00

Interesting as I'm using Multi Pass too (on the Oculus you can't do Single Pass right now) and I still can only see the decal from a single eye:

image

RamonBeast avatar Jan 18 '21 19:01 RamonBeast

In case anyone finds this in the future I found this option in Project Settings > Player > XR Settings > Stereo Rendering Mode

ShaunElerySwanson avatar Sep 23 '21 15:09 ShaunElerySwanson

Still experiencing this issue in 2022, anyone know any alternative solutions? I just need a drop shadow for the character in my 3D platformer but in the VR build it only renders in 1 eye

timothy92 avatar Aug 16 '22 03:08 timothy92

I ended up going for the Lux URP Essentials asset for my project. The projectors worked out of the box in VR.

It's a paid asset but it often goes on sale, and it has a lot of other interesting features for URP (especially the volumetric lights).

Le mar. 16 août 2022 à 05:41, timothy92 @.***> a écrit :

Still experiencing this issue in 2022, anyone know any alternative solutions? I just need a drop shadow for the character in my 3D platformer but in the VR build it only renders in 1 eye

— Reply to this email directly, view it on GitHub https://github.com/ColinLeung-NiloCat/UnityURPUnlitScreenSpaceDecalShader/issues/13#issuecomment-1216106643, or unsubscribe https://github.com/notifications/unsubscribe-auth/AJP24VUWYOKSQ5T2R7GVQVTVZMEW7ANCNFSM4OYZLUXA . You are receiving this because you authored the thread.Message ID: <ColinLeung-NiloCat/UnityURPUnlitScreenSpaceDecalShader/issues/13/1216106643 @github.com>

alexis-dupuis avatar Aug 16 '22 11:08 alexis-dupuis

If you landed on this issue trying to have (default URP) decals working on Oculus Quest 2:

In URP Renderer settings I'm using:

  • Depth texture mode "Force Prepass"

And in the Decal feature :

  • Technique -> "Screen Space"

I hope this might help fixing the issue with this shader too.

(Testing it today with Unity 2021.3.12f it is working without any problem)

ariok avatar Apr 07 '23 18:04 ariok