|
![](/i/fill.gif) |
I'm trying to export data from Blender.
If you have ever used Blender you will see that the Y axis is pointing
forward and the Z axis is pointing up.
My problem is that I need to flip everything so that the Y axis is up
and the Z axis is forward, so basically swapping the two.
For vectors it's easy, just swap y and z :
[x, y, z] becomes [x, z, y]
and after a lot of searching on the internet I even how to flip a matrix:
{ rx, ry, rz, 0 }
{ ux, uy, uz, 0 }
{ lx, ly, lz, 0 }
{ px, py, pz, 1 }
becomes
{ rx, rz, ry, 0 }
{ lx, lz, ly, 0 }
{ ux, uz, uy, 0 }
{ px, pz, py, 1 }
Both of these seem to work but I can't find how to flip a quaternion.
Post a reply to this message
|
![](/i/fill.gif) |