ViewComponent

Native view component.

Provides access to a native view component instance.

.TypeName: string 

.far: number 

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.

.fov: number 

Get the horizontal field of view for the view, in degrees.

If an XR session is active, this returns the field of view reported by the device, regardless of the fov that was set.

.fov 

Set the horizontal field of view for the view, in degrees.

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.

.near: 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.

.projectionMatrix: Float32Array 

Equivalent to getProjectionMatrix.

Note: Prefer to use getProjectionMatrix for performance.

.getProjectionMatrix<T>(out: T) ⇒ T 

.getProjectionMatrix() ⇒ Float32Array

Projection matrix.

Returns: The out parameter.

ParamTypeDescription
outTDestination array/vector, expected to have at least 16 elements.
Template ParamType Definition
Textends NumberArray