Originally Posted By: ventilator
why would that need my own routines? it's just a normal matrix concatenation.

matrix = tm * rm * sm
for v in vertices: v = v * matrix

...and transforming 100 thousand vertices isn't something you usually have to do in gameplay code. laugh


You got it. This is exactly what I mean. I just wanted to point out that it might be better to do it that way instead of using roate(), move() and scale() after each other for such a big mesh.

I am not sure about your example since in most books and in the OpenGL examples it would be matrix*v, but maybe you are talking about an DirectX notation.

And yes, a standard mesh will probably not have 100 thousand vertices. This was just an example to exaggerate the performance problem a bit. You will rather do something like that for smaller meshes but maybe several ones.


Models, Textures and Games from Dexsoft