Yes I have only the weekend to code so I don´t want to waste all my time with this one.

I want to rotate a vertex by the OpenGl-Rotation-Matrix-myself.I do it this way:

//Types:

typedef vertex float[3];//[0]=x,[1]=y,[2]=z

typedef matrix4x4 float[16];

//Code:

vertex V,vrot;

matrix4x4 M;

glMatrix(GL_MODELVIEW);//is it called glLoadMatrix??,doesn´t´matter…

glRotatef(xrot,…);

glRotatef(yrot,…);

glGetFloatV(GL_MODELVIEW,matrix4x4);

vrot[0]=M[0]*V[0] + M[1]*V[1] + M[2] *V[2];

vrot[1]=M[4]*V[0] + M[5]*V[1] + M[6] *V[2];

vrot[2]=M[8]*V[0] + M[9]*V[1] + M[10]*V[2];

Is this correct?

This seems to give me wrong results,but it is part of another (alot more complex)caculation so I just want to know if this is wrong or not.(It seems that this code is the prob,but I don´t know what is wrong in here)

Please help me fast and thanx in advance,XBTC!

[This message has been edited by XBCT (edited 06-24-2000).]