Notifications
Clear all

[Closed] Flip Matrix on X and Y Axis in World Space

What is an easy way of flipping a matrix on the X and Y axis in world space?

2 Replies

Try this: multiply each vector in the matrix by [-1,-1,1].


p = point()
p.rotation = (random (quat -1 -1 -1 0) (quat 1 1 1 1))
p.pos = [(random 0.0 50.0),(random 0.0 50.0),(random 0.0 50.0)]

m = p.transform
r = [-1,-1,1]
mi = (matrix3 (m[1]*r) (m[2]*r) (m[3]*r) (m[4]*r))
p2 = point()
p2.transform = mi

Thanks Richard, that is what i ended up doing. I was not sure if there was a better way of doing this since it’s results in a negative transform. But then i just realized i can correct that afterwards.

Thank you.