Skip to main content
gamedev.net
🔒 Locked

Transformations

Started by crossbrigade2000 May 9, 2003 at 9:57 AM 8 replies 600+ views
Original Post
crossbrigade2000
crossbrigade2000
Hi yee all doing out there? The problem I have is that I want to be be able to do certain transformations and this has to be done using matrices. Would someone be able to help me out? Thank you kindly
JuNC
JuNC
What transformations are you trying to do? You never actually stated what your problem was, just that you had one.
yodaman
yodaman
Im not sure if this will help you... but try using
matrix[16];
...do transformations, rotations etc
glLoadMatrixf(matrix);

Im not posative, but I think you can use this in place of glTranslate/glRotate()

http://www.ultimategameprogramming.com/OpenGLPage6.htm
go to the Cmatrix4x4 class tutorial

www.jinx.com www.thebroken.org www.suprnova.org www.mozilla.org
styrpe
styrpe
try gametutorials.com.
in the lesseon of rotation and translation in opengl, they explain you the transfomations of them
Watamerigonsu
crossbrigade2000
crossbrigade2000
Hi there
CAn somebody help with the following:

[cos(B) -sin(B) 0][x]
[sin(B) cos(B) 0] [y]
[0 0 1] [1]


A suare has the following points
(2,5)
(2,3)
(4,3)
(4,5)

I need to use the above quation to rotate the square anti-clockwise about the origin in the x/y plane by an angle of 90 degrees.
Can somebody help me out?
Nemesis2k2
Nemesis2k2
You actually don''t need to use matrix mathematics for this perticular problem. There''s a pretty cool and simple solution for this.


A 90 degree counterclockwise rotation on the x/y plane (around the z-axis) can be defined as:

pos = -y, x

Where x and y are the x and y coordinates of the point you want to transform.

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.