Capítulo 532 de 859
Represents the frustum of a CSM instance.
import { CSMFrustum } from 'three/addons/csm/CSMFrustum.js';
Constructor
| Signature |
|---|
new CSMFrustum( data : CSMFrustum~Data ) |
Properties
| Property | Description |
|---|---|
.vertices : Object | An object representing the vertices of the near and far plane in view space. |
.zFar : number | The zFar value. |
.zNear : number | The zNear value. This value depends on whether the CSM is used with WebGL or WebGPU. Both API use different conventions for their projection matrices. |
Methods
| Method | Description |
|---|---|
.setFromProjectionMatrix( projectionMatrix : Matrix4, maxFar : number ) : Object | Setups this CSM frustum from the given projection matrix and max far value. |
.split( breaks : Array.<number>, target : Array.<CSMFrustum> ) | Splits the CSM frustum by the given array. The new CSM frustum are pushed into the given target array. |
.toSpace( cameraMatrix : Matrix4, target : CSMFrustum ) | Transforms the given target CSM frustum into the different coordinate system defined by the given camera matrix. |