Methods
setOrthographic(left, right, top, bottom, near, far) → {ProjectionMatrix}
- Source:
Set the projection matrix to an orthographic projection.
Parameters:
Name | Type | Description |
---|---|---|
left |
number | The left edge. |
right |
number | The right edge. |
top |
number | The top edge. |
bottom |
number | The bottom edge. |
near |
number | The near-cutoff value. |
far |
number | The far-cutoff value. |
Returns:
Returns this projection matrix.
- Type
- ProjectionMatrix
setPerspective(fov, aspect, near, far) → {ProjectionMatrix}
- Source:
Set the projection matrix to a perspective projection.
Parameters:
Name | Type | Description |
---|---|---|
fov |
number | The field of view. |
aspect |
number | The aspect ratio (width / height). |
near |
number | The near-cutoff value. |
far |
number | The far-cutoff value. |
Returns:
Returns this projection matrix.
- Type
- ProjectionMatrix