WebXRNearInteraction SelectionMesh Bug Report & Feature Request

Following bug appears in this Playground example:
Playground Example

The position of the selectionMesh is often incorrect—it appears on the floor instead of on top of the button when trying to press the button. I’ve experienced similar issues in every scene I’ve created, and I can’t find the cause.

Due to this bug, I’d like to completely hide the selectionMesh.

    protected disableNearInteractionSelectionMeshes() {
        // Find all meshes with the name "nearInteraction"
        const nearInteractionMeshes = this.scene.meshes.filter(mesh => mesh.name === "nearInteraction");

        // Iterate over the meshes and disable them
        nearInteractionMeshes.forEach(mesh => {
            mesh.setEnabled(false);
            console.log(`${mesh.name} is set to disabled`);
        });
    }
  • Additionally, using Near Interaction sometimes feels imprecise. For example, hitting a slider is difficult unless the slider is made very tall. I might write more about this in the future.
1 Like

Thanks for reporting!

This should not happen, of course :slight_smile: I will have to dig in and understand what happened there.

And of course, your points make sense and will be taken into account when I fix the bug (and add the features).

We sadly have no visual tests for webxr (because of the complexity), so this has not been caught in a previous change made to some other functions. This PR will fix it:

2 Likes