Skip to content

modern-pdf-lib


modern-pdf-lib / rotationMatrix

Function: rotationMatrix()

rotationMatrix(angle, cx, cy): [number, number, number, number, number, number]

Defined in: src/core/operators/state.ts:178

Build the six-component matrix array for a rotation about an arbitrary centre point (cx, cy).

Useful when you need to compose this with other transformations before emitting operators.

Parameters

angle

Angle

cx

number

cy

number

Returns

[number, number, number, number, number, number]

[a, b, c, d, tx, ty]

Released under the MIT License.