const cylinderLayer = xrGlBinding.createCylinderLayer({
space: xrReferenceSpace,
viewPixelWidth: 1200,
viewPixelHeight: 600,
centralAngle: (60 * Math.PI) / 180,
aspectRatio: 2,
radius: 2,
transform: new XRRigidTransform(/* … */),
});
cylinderLayer.aspectRatio; // 2XRCylinderLayer: aspectRatio property / notebook
XRCylinderLayer: aspectRatio property
Runnable notebook: every JavaScript, HTML and CSS example on this page executes in a sandboxed local frame. Nothing leaves the browser.