rustgd / cgmath

A linear algebra and mathematics library for computer graphics.
https://docs.rs/cgmath
Apache License 2.0
1.12k stars 155 forks source link

Special method for combined invert + transpose for matrices #549

Open Panzerschrek opened 2 years ago

Panzerschrek commented 2 years ago

Sometimes it's necessary to calculate inverse + transpose matrix, to calculate proper normals matrix, for example. There are (of course) methods to do this. But (i presume) it is not an optimal solution, because invert methods already contain transpose operation. I suggest to add methods like invert_and_transpose, equivalent to invert but without transpose in last step.