AROcclusionManager not working with scaled ARSessionOrigin

Hi,

I’m excited to try out occlusion with the new AROcclusionManager from the latest ARFoundation samples, however it doesn’t seem to work in our project whenever we have a non-1 scale on the ARSessionOrigin.

We use ARSessionOrigin to place game content on a user-selected position on the detected planes. We also change its transform.localScale (to a high number) to scale the content (down).

When the scale is set to high numbers, I don’t see anything because (I’m pretty sure), it’s interpreting the distance values for occlusion in real-world meters, but of course everything in my digital (massively bigger, but scaled down) world is in tens of metres, so it fails any depth tests.

Does anyone know of a good workaround for this in the meantime? Would it be possible to poke in the scale to a custom material on the ARCameraBackground, if I made one? Or am I doing something else wrong? I’ve posted a bug report, too, so hopefully that’s working its way through the Unity tubes.

My versions of things:

Unity 2019.4.4f1
ARFoundation 4.1.0-preview.5
Set to Android platform

I found a workaround for this and posted it here: Using AROcclusionManager and scaled ARSessionOrigin occludes everything

Sorry for the duplicate thread.