AR example shows an error message

I try the AR example link and click “Start AR” :
https://threejs.org/examples/?q=webxr#webxr_ar_cones

I saw a warning message :

THREE.WebGLRenderer: Can’t change size while VR device is presenting.
WebGLRender.setSize @three.moudle.js:25726
onWindowResize @webxr_ar_cones.html:80

Is this a problem ?

Related issue:

1 Like

You can try this :

// Assuming your renderer is named 'renderer'

// Check if the VR device is presenting
const isVRPresenting = renderer.xr.isPresenting;

// Change the size only if the VR device is not presenting
if (!isVRPresenting) {
  renderer.setSize(newWidth, newHeight);
}

// The rest of your rendering code...