Multiplying matrixes for child objects
Posted: Sat Jun 07, 2014 5:12 am
So.......
I have my decal how I want it in the sim, with the exception of needing to scale it a bit and rotate it through 90 degrees too.
So for the scaling matrix I have:
[2.25 0 0]
[0 2.25 0]
[0 0 1]
The rotation matrix I require is for a 90 degree rotation clockwise, which is:
[0 0 1]
[0 1 0]
[-1 0 0]
However, when i multiply them together and input my resulting matrix to the .bin file, I lose scaling in one axis but the object rotates exactly how I desire. The result matrix I have (which may of course be totally wrong) is:
[0 0 0]
[0 2.25 0]
[-1 0 0]
Please, could someone help rescue me from trig calculations and insanity.
Thank you.
I have my decal how I want it in the sim, with the exception of needing to scale it a bit and rotate it through 90 degrees too.
So for the scaling matrix I have:
[2.25 0 0]
[0 2.25 0]
[0 0 1]
The rotation matrix I require is for a 90 degree rotation clockwise, which is:
[0 0 1]
[0 1 0]
[-1 0 0]
However, when i multiply them together and input my resulting matrix to the .bin file, I lose scaling in one axis but the object rotates exactly how I desire. The result matrix I have (which may of course be totally wrong) is:
[0 0 0]
[0 2.25 0]
[-1 0 0]
Please, could someone help rescue me from trig calculations and insanity.
Thank you.