edwong
09-28-2003, 06:06 PM
hi,
i have defined th following perspective as my view plane:
glViewport (0, 0, (GLsizei) w, (GLsizei) h);
glMatrixMode (GL_PROJECTION);
glLoadIdentity ();
gluPerspective(45.0, (GLfloat) w/(GLfloat) h, 5.17, 10.7);
glMatrixMode(GL_MODELVIEW);
glLoadIdentity();
glTranslatef (-0.1, -1.6, 7.9);
glRotatef(-90,1,0,0);
glRotatef(-30,0,0,1);
glRotatef(0,1,0,0);
glTranslatef(-0,-0,-0);
glScalef(1,1,-1);
then i try to output a sphere
glTranslatef(0,0,0.08);
glScalef(0.275,0.152,0.153);
qobj = gluNewQuadric();
gluSphere(qobj,1,10,10);
it just won't show up on the screen.
any idea what's wrong??
thank you
i have defined th following perspective as my view plane:
glViewport (0, 0, (GLsizei) w, (GLsizei) h);
glMatrixMode (GL_PROJECTION);
glLoadIdentity ();
gluPerspective(45.0, (GLfloat) w/(GLfloat) h, 5.17, 10.7);
glMatrixMode(GL_MODELVIEW);
glLoadIdentity();
glTranslatef (-0.1, -1.6, 7.9);
glRotatef(-90,1,0,0);
glRotatef(-30,0,0,1);
glRotatef(0,1,0,0);
glTranslatef(-0,-0,-0);
glScalef(1,1,-1);
then i try to output a sphere
glTranslatef(0,0,0.08);
glScalef(0.275,0.152,0.153);
qobj = gluNewQuadric();
gluSphere(qobj,1,10,10);
it just won't show up on the screen.
any idea what's wrong??
thank you