residualvm/residualvm — pull request #839 by somaen (2014-02-20 18:41:14+00:00)
Title: TINYGL: Reformat the code a bit, and some minor adjustments.

TinyGL still doesn't conform to our code formatting-conventions, this is atleast one more step in that direction:
* Change C-isms to C++-isms (atleast for for-loops and structs)
* Run astyle with ScummVM's settings (and some that might be a tad stricter)
* Change pass-by-pointer to pass-by-const-pointer, and pass-by-value to pass-by-const-reference in zmath.

This is just a first quick attempt, which interestingly uncovered some oddities:
* gl_M4_InvOrtho has an odditiy where it's inner for-loop reuses the counting variable of the outer for-loop
* lists.cpp's glGenLists too
* glopRotate() in matrix.cpp has indentation that suggests the code following the one-line if was part of the if, but isn't.

Future fixes might include changing the matrix-math to reuse our math/matrix{4/3}-classes.

I might push a few more changes to this PR later on, but thought I'd let people comment on the general direction.