WebXR movement on VR. Change camera type on Web

Hi,
I need to have different camera for display 3D object to web and display by VR.

I need, on VR, possibility to movement. I see the documentation WebXR Selected Features | Babylon.js Documentation (babylonjs.com)
and this Playground XR Movement Feature | Babylon.js Playground (babylonjs.com) but it’s same camera (web and VR).

If I use BABYLON.ArcRotateCamera, on VR, movement it’s by Teleportation (I disabled this options).
If I use BABYLON.FreeCamera, movement it’s working on Web and VR. (but I need only on VR).

So I need BABYLON.ArcRotateCamera on Web, and BABYLON.FreeCamera on VR; it is possible?

cc @RaananW

That’s the only way it works, actually. Are you sure you use WebXR (and not the deprecated WebVR)?

1 Like

Uhm, you are right.

I tested on playground and it’s working, with part of my code

WebXR and Web Testing | Babylon.js Playground (babylonjs.com)

I think I have some code that I need to remove on my implementation.

Thanks

1 Like