User Tools

Site Tools


Row Major vs Column Major

In the era of programmable shaders this is irrelevant.

Fact. Multiplying matrices is essentially taking the sum of the multiplications of rows from matrix A and the columns of matrix B.

If you swap the order of multiplications you have inverted the meaning of “matrix A” and “matrix B”.

Perspective Transform and glDepthRange

This is an utter nightmare! Why? Because it is so easy to get wrong and then see… NOTHING.

more soon

Orthographic Projection and Z Depth Testing

This is an incredibly useful feature. Don't waste the 3rd dimension just because you world is flat!

An orthographic projection means that objects are the same size regardless of how far away they are. e.g. no matter what 'z' is x and y are NEVER scaled.

However, 'z' is still passed through to the z-buffer this you can use it for hidden surface removal and the like.

Some Code That Will Let You Play With Matrices

I really like this application.

Within it is my 'vmath' library and a string binding

The application will show the tree of mul/adds required to perform a matrix operation. You will find many optimisations in this lot. Especially X * -1, X * 0, X + 0.

Enjoy! (offline while the public access Git server is fixed)

opengl_insights.txt · Last modified: 2017/01/12 13:02 by xylene