Mesh Occlusion Seems not to work in Virtual Studio

Include the following details while filing a bug report (edit as applicable):

  • Issue category: Real-time Mapping-Depth
  • Host machine & OS version: Windows
  • Issue Environment : Unity Virtual Studio
  • ARDK version: 2.1
  • Unity version: 2020.3.19f1

Mesh Occlusion in Unity does not work.

I have followed all the instructions:
I selected MeshInteriorScene in Virtual Studio, as you can see.
ARMeshManager and MeshController are present in the scene.
When i Hit play the Car is not being occluded.

Also when I activate “ShowWorldMesh” nothing happens.

But I discovered that if I disable the GameObject Mock in MeshInteriorScene(clone), I can visualize the scene with a custom material applied to the world mesh. But the car is not yet being occluded.

Anyway, I expected a behavior similar to the one shown here.

https://lightship.dev/templates/mesh-occlusion/

However it is important to note that when I build the application everything works correctly.

Can you tell me what I am doing wrong?

Best regards

You need to add the depth manager script and enable occlusion there. Right now I don’t see anything enabling occlusion

Thank you for replying,
Yes that I did and it works, but I thought it was not necessary, since in the template does not bring it by default.
Another thing, why in Mesh Controller when I enable, Show World Mesh, it does not show me the mesh.

Did you test on device? (Make sure to disable occlusion if you want to see the mesh)

As I said before, on the device it works perfectly, but in virtual studio it does not behave as in the post.
https://lightship.dev/templates/mesh-occlusion/

Yeah, I also didn’t get it working properly in editor. Maybe file a bug report post about it?

Sure, if you can report the bug, it would be perfect.

I’m not working in lightship anymore. Just make a bug report post

Hi Sergio,

I was able to replicate this issue on the Unity Editor as well and found that with no ARDepthManager included, you should be getting the following message in the console:

#Niantic.ARDK.AR.Configuration._ARConfigurationValidator#: Enabling depth because meshing was enabled. Use the ARDepthManager component or the IARWorldTrackingConfiguration properties to further configure depth functionality.

What this means is that depth is being enabled but there is no configuration going on so everything is at the default settings which means that the DepthManager will have a value of None for Occlusion. This would explain why it works when you manually add depth, since you’re likely not setting it to None and you’re actually giving it a value.

It seems that the reason it’s working on device is that our developers added additional checks to configure some settings to have depth when on mobile but when on Editor, nothing is being configured and it’s left up to the developer to configure depth for their project