Vr.prototype.onStart = function () {
this.checkButton(true);
console.error('XR Started: ' + this.app.xr.camera.camera.farClip); // reports 1000
this.app.xr.camera.camera.farClip = 10000;
console.error('Updated far clip: ' + this.app.xr.camera.camera.farClip); // still reports 1000
};
Any ideas what might be going wrong? I need it to be 10000, as the app allows the user to fly around in 3D tiles in VR, which means the horizon would ideally be quite far away.
Essentially - it works when I preview the experience in the browser (and interestingly in an XR emulator), but as soon as I fire up the VR experience in the Vision Pro, the farClip reduces substantially.
I have to split this into two separate posts:
e.g. Here’s the view in the regular browser (on the Vision pro emulator):
You can see that the 3D tiles data gets substantially clipped in the XR experience. So I put the code in to A) try to debug what was going on (that’s how I’m seeing that the farClip in the XR camera is reporting as 1,000) and B) to try to force-fix it.
WebXR API forces camera near/far clips on the camera, so you cannot change them. This is sort of in a hands of implementation (Apple Vision Pro in this case).
So you have to try to take their far clip into the consideration, and design content with that in mind.
Apple Vision Pro thinks you have to see only 1 kilometer in the distance