#WebXR (AR) green cube?

1 messages · Page 1 of 1 (latest)

lunar berry
#

I noticed that a small green cube appears when using WebXR and WebARSessionRoot underneath the model that I'm displaying, is there a way of deactivating it?

modest birchBOT
modest birchBOT
# lunar berry I noticed that a small green cube appears when using WebXR and WebARSessionRoot ...

The green cube appearing beneath your model in WebXR is part of the preview feature for touch transform. To deactivate it, set arTouchTransform to false on the WebARSessionRoot component (see the documentation). Here's an example of how to adjust that property in your component:

export class MyWebARComponent extends Behaviour {
    awake() {
        const webARSessionRoot = this.getComponent(WebARSessionRoot);
        if (webARSessionRoot) {
            webARSessionRoot.arTouchTransform = false;
        }
    }
}

Make sure to call this in the awake or start lifecycle method of one of your components to ensure that the WebARSessionRoot component has been initialized before you try to access it.

1 messages left GPT 4
thread_nKHdmPBW6rcoI2TV9lVeAzlE

lunar berry
#

Hmm kinda... I already have arTouchTransform disabled from the Editor, so it shouldn't appear in that case.

#

I think this is a bug. I just tested it out, with the setting disabled and enabled in the editor, yet the cube remains

orchid dawn
#

It is the default XR Avatar. On the WebXR component, select none in the avatar selection field.