hey!
i've made these functions to rotate points in a 3d world...
VB Code:
Const PiDiv180 As Double = 1.74532925199433E-02 Public Function RotateXX(X As Double, Z As Double, Deg As Double) RotateXX = Z * Sin((Deg) * PiDiv180) + X * Cos((Deg) * PiDiv180) End Function Public Function RotateXZ(X As Double, Z As Double, Deg As Double) RotateXZ = Z * Cos((Deg) * PiDiv180) - X * Sin((Deg) * PiDiv180) End Function Public Function RotateYY(Y As Double, Z As Double, Deg As Double) RotateYY = Y * Cos((Deg) * PiDiv180) - Z * Sin((Deg) * PiDiv180) End Function Public Function RotateYZ(Y As Double, Z As Double, Deg As Double) RotateYZ = Y * Sin((Deg) * PiDiv180) + Z * Cos((Deg) * PiDiv180) End Function
these functions doesnt rotate around all 3 angles in a 3d world...only 2 of them...can anyone help me with the 3rd one?




Reply With Quote