4 ms·
> Turns out, software matrix multiplication is not the best way of doing 3D graphics ok, what is? all the 3d engines I've ever worked with do tons of software
by gfxgirl 5y ago
> Turns out, software matrix multiplication is not the best way of doing 3D graphics
ok, what is? all the 3d engines I've ever worked with do tons of software matrix multiplication. You generally need to know where things are for collision checking and other things so doing it all on the gpu is not an option
- marginalia_nu 5y ago> You generally need to know where things are for collision checking and other things so doing it all on the gpu is not an option Sure. You can do some of it in software. That's fine. Point is I didn't use the GPU at all, and did all the rendering in software. No matter how you rotate or translate it, that's not a particularly efficient way of doing it.
- marcosdumay 5y agoAnyway, the GPU usually does it with matrix multiplications.
- Simplicitas 5y agoSo what are some of the more efficient ways of doing it, if it's not too much to ask? :-)
- marginalia_nu 5y agoTo have the GPU do the work for you. A series of calls to OpenGL is a heck of a lot easier than setting up 3x3 rotation and translation-matrices and implementing a library to do 3x1, 1x3, 3x3 matrix multiplications, scalar transformations, transpositions, calculating determinants, planar projections, perspective shifts, and what have you.
- nicwolff 5y agoQuaternions? https://en.wikipedia.org/wiki/Quaternions_and_spatial_rotation https://en.wikipedia.org/wiki/Quaternions_and_spatial_rotati... https://stackoverflow.com/questions/8919086/why-are-quaternions-used-for-rotations https://stackoverflow.com/questions/8919086/why-are-quaterni...