Is it posible to have the euler angle from a rotation matrix? Im stuck thinking about it.
This is the only clue I had.
; +,+ = 0-90
; +,- = 90-180
; -,- = 180-270
; -,+ = 270-360
fGetVectorLen proc uses esi edi lpV:dword
mov esi,lpV
fld [esi].VERTEX.x
fmul [esi].VERTEX.x
fstp [esi].VERTEX.x
fld [esi].VERTEX.y
fmul [esi].VERTEX.y
fstp [esi].VERTEX.y
fld [esi].VERTEX.z
fmul [esi].VERTEX.z
fstp [esi].VERTEX.z
fld [esi].VERTEX.x
fadd [esi].VERTEX.y
fadd [esi].VERTEX.z
ret
fGetVectorLen endp
invoke Vec_Sub,addr vR,lpfPos,addr VPosa ; Vector subtraction, from the Delta, we will determined is what is the euler angle.
invoke fGetVectorLen,addr vR
http://en.wikipedia.org/wiki/Euler_angles
about half-way down the page, you will see 6 equations
FSQRT is missing in fGetVectorLen
Quote from: qWord on January 14, 2012, 12:51:07 PM
FSQRT is missing in fGetVectorLen
Oh, youre right, Im clumsy again. ThanksĀ :U
I never done something when Im alone.
I should be able to extract the euler angle degree information if I used atan on a 2D coordinate, but I dont know is it posible on 3D equations.
It should be
X=dX/len
Y=dY/len
Z=dZ/len