-
Notifications
You must be signed in to change notification settings - Fork 18
Description
Line 4628 in 3a5955b
| const mat = mul(mul(rotate_origin, scaling(3, 4, 5)), translation(6, 7, 8)); |
I'm trying to unconfuse myself on exactly which order I should apply matrices to a vector using zmath functions.
While searching for an answer, I stumbled upon this line of code.
If convention is that, in order to achieve correct transformations, objects should be transformed in this order:
First: Scale -> then Rotate -> Last: Translate
then why is this line seemingly using a different order of operations?
I know the difference might be irrelevant for the test, or the test might be checking for different numbers where this order does not even make a difference.
But if tests are the only source of documentation/truth for this library...
shouldn't they operate in the expected order, such as to not confuse potential adopters of the code?