The documentation for Matrix4.compose states:
"Sets this matrix to the transformation composed of position, quaternion and scale. Internally this calls makeRotationFromQuaternion( quaternion ) followed by scale( scale ), then finally setPosition( position )."
My understanding was always that you should scale before doing the rotation otherwise you can end up with unusual scaling (skewing).
So it should be (IMHO): scale, rotation, translation
The documentation is outdated. Matrix4.compose() does not call the mentioned methods. The following sentence should be completely removed:
Internally this calls makeRotationFromQuaternion( quaternion ) followed by scale( scale ), then finally setPosition( position ).
Do you want to make a PR with this change?
Right. The docs are not the place to describe how the code is implemented.
Thanks for the info @Mugen87 and agree with the docs not describing how the code works.
I may still be getting a difference between doing .compose and doing the matrix multiplication manually (as scale, orientation, translation) but I need to do a bit more digging before I raise that as a bug since it might very well be a PICNIC (Problem In Chair, Not In Computer). 馃ぃ
Raised PR with documentation update so closing this issue.
Most helpful comment
Right. The docs are not the place to describe how the code is implemented.