Advertisement

gluLookAt

Started by February 09, 2001 06:11 AM
0 comments, last by VanDenProut 24 years ago
Hi, I have a little question (I''m a beginner) Let''s suppose you have a triangle (-15,13,16),(-15,-18,16),(18,13,16) What are the arguments for the call of gluLookAt to see the triangle ? Thks Chris
void gluLookAt(
GLdouble eyex,
GLdouble eyey,
GLdouble eyez,
GLdouble centerx,
GLdouble centery,
GLdouble centerz,
GLdouble upx,
GLdouble upy,
GLdouble upz
);

thats the definition of it(by MS)

what you do is for example set eye to (0,0,0), this means you eye is positioned in the origin.
next up you set the center values to where you want to look at, in you case you could use either of the triangles corners,or an average between them all.

The up coordinates specify how the camera is tilted... just start out with (0,1,0) or (1,0,0) and see if you can figure it out
Jonas Meyer Rasmussenmeyer@diku.dk

This topic is closed to new replies.

Advertisement