Forum Discussion
fancyfennec
9 years agoExplorer
Oculus gaze pointer issues - disappears behind objects
Hi,
I'm trying to recreate the gaze pointer tutorial you can find here:
https://developer.oculus.com/blog/unitys-ui-system-in-vr/
If I use their project and create my own scene, I can reproduce the gaze pointer and it is behaving normally. But if I start with a blank project, and recreate the exercise, the gaze pointer disappears behind other objects. I must've tried a dozen different ways to do it, still getting the same results.
I compressed my Unity scene and uploaded it. I would be eternally grateful if someone could take a look at it and tell me what I'm doing wrong. I've been trying to figure it out and it's driving me nuts. I already posted this in the Unity forums but so far, no answer yet.
Link to scene here:
https://www.dropbox.com/sh/jhd8tqs2cv74up3/AABCs57QnGkzryMk8hC9ve4Ta?dl=0
Thank you, your help is greatly appreciated.
Using Unity 5.4 beta and Oculus, Windows 10
I'm trying to recreate the gaze pointer tutorial you can find here:
https://developer.oculus.com/blog/unitys-ui-system-in-vr/
If I use their project and create my own scene, I can reproduce the gaze pointer and it is behaving normally. But if I start with a blank project, and recreate the exercise, the gaze pointer disappears behind other objects. I must've tried a dozen different ways to do it, still getting the same results.
I compressed my Unity scene and uploaded it. I would be eternally grateful if someone could take a look at it and tell me what I'm doing wrong. I've been trying to figure it out and it's driving me nuts. I already posted this in the Unity forums but so far, no answer yet.
Link to scene here:
https://www.dropbox.com/sh/jhd8tqs2cv74up3/AABCs57QnGkzryMk8hC9ve4Ta?dl=0
Thank you, your help is greatly appreciated.
Using Unity 5.4 beta and Oculus, Windows 10
6 Replies
Replies have been turned off for this discussion
- AndyBorrellProtegeThanks for finding this. It's a bug in the shader code. You can fix it by finding "Assets\Shaders\Particle Alpha Blend-AfterTrans.shader" and deleting the following lines:#ifdef SOFTPARTICLES_ONo.projPos = ComputeScreenPos (o.vertex);COMPUTE_EYEDEPTH(o.projPos.z);#endif
and:#ifdef SOFTPARTICLES_ONfloat sceneZ = LinearEyeDepth (SAMPLE_DEPTH_TEXTURE_PROJ(_CameraDepthTexture, UNITY_PROJ_COORD(i.projPos)));float partZ = i.projPos.z;float fade = saturate (_InvFade * (sceneZ-partZ));i.color.a *= fade;#endif - fancyfennecExplorerThank you!
- fancyfennecExplorerHi, sometimes this error pops up: "output parameter 'o' not completely initialized" from the same shader. Do you have any idea what that could be? Thanks
- AndyBorrellProtegeDeleting the softparticle from the vertex structure should fix this. I.e. remove the lines:#ifdef SOFTPARTICLES_ONfloat4 projPos : TEXCOORD1;#endif
- JDavidLHonored GuestHi! this is the first time I write in the forum. The reason is a similar problem: The Gaze pointer in my scene some times is behind the objects and some time is in front of them, depending on the Z position when intersects the object collider... or it seems to be something like that... My issue is that i am not using the "Particle Alpha Blend-AfterTrans.shader" at all...
I'm using Unity 5.3.5 and OVR utilities 1.6.0 and some scripts of the OculusSampleFrameworkProject.
I really appreciate some help! - tareksalahHonored GuestHi,
I tried this solution proposed by @andyborrel and it doesn't work.
Is there other thing to do?
Quick Links
- Horizon Developer Support
- Quest User Forums
- Troubleshooting Forum for problems with a game or app
- Quest Support for problems with your device
Other Meta Support
Related Content
- 4 months ago
- 1 year ago
- 3 years ago
- 3 months ago