ViewComponent
ViewComponent
Native view component
Provides access to a native view component instance
Kind: global class
.projectionMatrix ⇒ Float32Array
Kind: instance property of ViewComponent
Returns: Float32Array - Projection matrix
.near ⇒ number
Kind: instance property of ViewComponent
Returns: number - ViewComponent near clipping plane value
.near
Set near clipping plane distance for the view
If an XR session is active, the change will apply in the following frame, otherwise the change is immediate.
Kind: instance property of ViewComponent
Param | Type | Description |
---|---|---|
near | number | Near depth value |
.far ⇒ number
Kind: instance property of ViewComponent
Returns: number - ViewComponent far clipping plane value
.far
Set far clipping plane distance for the view
If an XR session is active, the change will apply in the following frame, otherwise the change is immediate.
Kind: instance property of ViewComponent
Param | Type | Description |
---|---|---|
far | number | Near depth value |
.fov ⇒ number
Get field of view for the view
If an XR session is active, this returns the field of view reported by the device, regardless of the fov that was set.
Kind: instance property of ViewComponent
Returns: number - ViewComponent horizontal field of view in degrees
.fov
Set field of view for the view
If an XR session is active, the field of view reported by the device is used and this value is ignored. After the XR session ends, the new value is applied.
Kind: instance property of ViewComponent
Param | Type | Description |
---|---|---|
fov | number | Horizontal field of view in degrees |