PDA

View Full Version : Direction of axes.



Sergei
11-09-2000, 12:16 AM
How to change an arrangement of axes?
That they would coincide axes in window.

Gavin
11-09-2000, 02:51 AM
Do you mean like this???

gluLookAt(0.0, 8.0, 100.0, /* eye is at (0,8,60) */
0.0, 2.0, 0.0, /* center is at (0,8,0) */
0.0, 1.0, 0.); /* up is in postivie Y direction */


gav

Sergei
11-09-2000, 04:08 AM
No. I set glLookAt (0,0,5, 0,0,0, 0,1,0);
Point with coordinates (0,0,0) placed in left down corner of OpenGL window and Y-axes direct to Up. The point (0,0,0) in Windows (Unix) window placed in Left Up corner. Y-axes direct to down. And when i take mouse coordinates from windows (unix) window, i must convert it to OpenGl coordinates.

How change direct Y-axes and place of point (0,0,0)??????

Gavin
11-09-2000, 05:21 AM
so are you just saying that the 0,0 is different in OpenGL to say X-Windows? in 2-D?

gav

Sergei
11-09-2000, 06:17 AM
Yes! that's what i meant. excuse me for my english.

Gavin
11-09-2000, 06:22 AM
just do something simple like
x = x
y = height-y

ok?

gav

Sergei
11-09-2000, 07:56 AM
Yes! That's easy. But, when need do it for 4000 scenes, which include ~1000 objects, whitch include ~20000 points. It's not good idea.

(All 4000 scenes show in one window)

http://www.opengl.org/discussion_boards/ubb/smile.gif

zed
11-09-2000, 10:55 AM
do this after u possition the camera
glScalef(1,-1,1)

not 100% if it'll work though
also do u see anything using gluLookAt(0,0,5, 0,0,0, 0,1,0);
a few too many zeros there for me liking

RandyU
11-09-2000, 01:24 PM
When you change axis orientation you change right pairs of vectors become left, so you have also to change glFrontFace from CCW to CW,else you'll see scene with bad normals(everything will be dark).