How to interact with Babylon.GUI elements in immersive-ar?

I have almost same problem as mentioned by this user , Cant interact with GUI.Button.CreateSimpleButton in WebXr immersive-ar mode. · Issue #8879 · BabylonJS/Babylon.js · GitHub

I am creating a simple 3d model viewer which should work in immersive-ar, but the problem is that the Babylon.GUI elements are not interactable during ar-session, I don’t know if its a bug or some mistake from my side, so here is my playground example =

the button is working fine in browser,

I am sure @RaananW can help with this :slight_smile:

I didn’t dive into your implementation (as I am mobile right now), but this example has a working UI, you might be able to debug yours based on that -

1 Like

can you please tell me if you are using it on android or iphone ?, I have tried the playground example you provided on my android phone, and its not working for me, whenever I click the button, the click event is not responding.

I will look into that. if it is not working it’s a regression that we need to solve. thanks for notifying us

I have found that its only not working when we are using fullscreenUI in WEBXR-immersive AR
when using it like

I tried with mesh panel like this


and the buttons are responding normally , I think the problem is not with GUI , but only with AdvancedDynamicTexture.CreateFullscreenUI

The issue was the pointer up event not triggered correctly.

This PR is fixing it. Android AR and Oculus VR tested.

1 Like

thank you for looking into this matter :slight_smile:

1 Like

this problem is there once again

@PolygonalSun might be able to have a look, as @RaananW will only be back in a couple weeks after the break

i’ll look into that this week. Are you saing you can’t interact with the GUI in AR mode now?

1 Like

Problem found and merged, will be up in the next nightly


thank you @RaananW , it has been solved, and its working fine