[quote]Euler lived as a very successful mathematician and inventor, but his skills in money-earning weren’t terribly great. A friend had covertly collected sums of earnings all from the profits off of Euler’s work. One day while feeling disappointed, Euler decided to travel to a relative out of state from boredom. His friend stopped him, politely asking that he make a puzzle toy for a daughter.
Since Euler enjoyed circles, he decided to form a puzzle out of the rim of one. He began to have fun to the point of accidentally discovering that certain multiples of flat lines could evenly join together. We profit today in 3D graphics since “round” objects are really made up of a bunch of triangles. This holds true even with NURBS.
The idea of a “unit circle” also applies to creating your own matrix. If the math calculates wrongly, things will bend oddly out of shape during a turn of some sort. A unit circle shows force applied to X and Y as a unit of 1. Add a third dimension as Z, and you have yourself a sphere.
Notice that X, Y, and Z all have a unit of 1. Basically, a matrix that allow circles also permits camera movement. To induce movement, you might first test out graphing a circle on an X and Y graph. With that complete, the third dimension Z will become compatible for your 3D matrix.
[/quote]
Probably I may not have been clear about my question…
a sequence of rotation xyz is mathematically calculated as RzRyRx (where R is a matrix).
Rz * Ry * Rx = [[czcy, -szcx + czsysx, szsx + cz cxsy]
[szcy, cxcz + szsysx, -sxcz + szsycx]
[ -sy, cysx, cycx]]
where cx = cos(x) sx = sin(x) etc…
Now… opengl is supposed to pre multiply the matrices then:
rotation sequence: xyz
glRotated(ax,1,0,0)
glRotated(ay,0,1,0)
glRotated(az,0,0,1)
and this should be the same of RzRyRy… but it seems like it’s not since
Rz * Ry * Rx correspond to :
glRotated(az,0,0,1)
glRotated(ay,0,1,0)
glRotated(ax,1,0,0)
and i am just wondering what am i doing wrong. I mean isn’t openGl pre multiplying or what?