|
|
Am 28.09.2018 um 03:27 schrieb Mike Horvath:
> Two important questions I have (that may not be explained in the docs),
> is how to convert a 3x3 rotation matrix to POV-Ray syntax, and how to
> determine the inverse matrix?
given a matrix
/ a b c \
( d e f )
\ g h i /
you have to specify either
matrix < a, b, c,
d, e, f,
g, h, i,
0, 0, 0 >
or
matrix < a, d, g,
b, e, h,
c, f, i,
0, 0, 0 >
The order depends on whether the original matrix is specified in
"mathematical" or "computer graphics" style - they're mirrored along the
diagonal. Can't remember which one POV-Ray uses.
Determining the inverse /transformation/ is simple:
#declare Foo = transform { matrix < ... > }
#declare FooInv = transform { Foo inverse }
Actually getting at the corresponding matrix is possible by applying the
inverted transformation to the axis vectors.
Post a reply to this message
|
|