Skip to main content

Function: getProjectionScaleMatrix()

getProjectionScaleMatrix(aspectRatio): mat4

Computes the projection scaling matrix used for canvas stretch. The scaling is applied along the canvas axes.

Parameters

aspectRatio: number[]

[scaleX, scaleY], where each value controls stretching along the corresponding canvas axis

Returns

mat4

Projection scaling matrix for canvas stretch

Defined in

packages/core/src/RenderingEngine/helpers/getProjectionScaleMatrix.ts:10