Trying to get a plane to track head movement in xr

I am trying to get a plane which is going to be used as a scoreboard to track head movements in xr, I am very sure I am probably doing it wrong.

Here is the playground :

In this I am assuming, that the free camera is the thing that tracks the xr headset.
I may also be making it update wrongly

Thanks in advanced for any help

I am not sure what you are trying to do, but the freecamera in your scene is only active when NOT in immersive mode. The camera you need is

FYI, is not actually used for rendering, just as a container for 2 rigCameras. Each has the same position & rotationQuaternion copied to it, but pretty sure that the container camera also has the same info.

See Babylon.js/webXRCamera.ts at master · BabylonJS/Babylon.js · GitHub, for _updateFromXRSession(), which is transfers the values from the device to the container camera & then the rig camera.

1 Like

thanks for the help, with that know all i needed to do was make it the parent