Package: graphene

Function graphene:matrix-to-2d

Lambda List

graphene:matrix-to-2d (matrix)

Syntax

(graphene:matrix-to-2d matrix) => (list xx yx xy yy x0 y0)

Arguments

matrix -- a graphene:matrix-t instance
xx -- a double float with the xx member
yx -- a double float with the yx member
xy -- a double float with the xy member
yy -- a double float with the yy member
x0 -- a double float with the x0 member
y0 -- a double float with the y0 member

Return Value

The list with the floating point values, or nil if matrix is not compatible with an affine transformation matrix.

Details

Converts the matrix to an affine transformation matrix, if the given matrix is compatible. The returned values have the following layout:
⎛ xx  yx ⎞   ⎛  a   b  0 ⎞
⎜ xy  yy ⎟ = ⎜  c   d  0 ⎟
⎝ x0  y0 ⎠   ⎝ tx  ty  1 ⎠  
This function can be used to convert between a graphene:matrix-t instance and an affine matrix type from other libraries.
 

See also

#2024-12-30