Skip to main content

Matrix4x4.Frustum(FrustumPlanes frustumPlanes)

This function returns a projection matrix with viewing frustum that has a near plane defined by the coordinates that were passed in.

Parameters:

NameTypeDescription
frustumPlanesFrustumPlanesFrustum planes struct that contains the view space coordinates of that define a viewing frustum.

Returns:

typeDescription
Matrix4x4A projection matrix with a viewing frustum defined by the plane coordinates passed in.

Usage

---@type FrustumPlanes
local frustumPlanes;


local val0 = Matrix4x4:Frustum(frustumPlanes)

a.org/pil/2.3.html) |The Y coordinate of the bottom side of the near projection plane in view space. | |top | number |The Y coordinate of the top side of the near projection plane in view space. | |zNear | number |Z distance to the near plane from the origin in view space. | |zFar | number |Z distance to the far plane from the origin in view space. |

Returns:

typeDescription
Matrix4x4A projection matrix with a viewing frustum defined by the plane coordinates passed in.

Usage

---@type number
local left;

---@type number
local right;

---@type number
local bottom;

---@type number
local top;

---@type number
local zNear;

---@type number
local zFar;


local val0 = Matrix4x4:Frustum(left, right, bottom, top, zNear, zFar)

Extra Detail

The corners of the near plane of the viewing frustum of the projection matrix are as follows:
top-left : (left, top, zNear)
top-right : (right, top, zNear)
bottom-right : (right, bottom, zNear)
bottom-left : (left, bottom, zNear)