XRCompositionLayer
WebXR Device API
WebXR Device API
The XRCompositionLayer interface of the WebXR Device API is a base class that defines a set of common properties and behaviors for WebXR layer types. It is not constructable on its own.
Several layer types inherit from XRCompositionLayer:
- XREquirectLayer
- XRCubeLayer
- XRCylinderLayer
- XRProjectionLayer
- XRQuadLayer
XRCompositionLayer itself inherits from the general XRLayer class (which inherits from EventTarget).
Instance properties
- XRCompositionLayer.blendTextureSourceAlpha
- : A boolean enabling the layer's texture alpha channel.
- XRCompositionLayer.layout
- : The layout type of the layer.
- XRCompositionLayer.mipLevels
- : The number of mip levels in the color and texture data for the layer.
- XRCompositionLayer.needsRedraw
- : A boolean signaling that the layer should be re-rendered in the next frame.
Instance methods
Inherits methods from its parent, EventTarget.
- XRCompositionLayer.destroy()
- : Deletes the underlying layer attachments.
Specifications
Browser compatibility
See also
- XRLayer
- EventTarget
- XREquirectLayer
- XRCubeLayer
- XRCylinderLayer
- XRProjectionLayer
- XRQuadLayer