how would i make a line, anywhere in the first quadrant rotate about the origin?
ChuckB
09-22-2002, 07:29 PM
Hi,
The rotate below will rotate the line about the +Z axis which points out of the screen.
angle += 0.1;
glRotatef(angle,0,0,1);
glBegin(GL_LINES);
glVertex3f(0,0,0);
glVertex3f(10,0,0);
glEnd();
. . .
The line above lies along X axis at 0 degrees.
That should work for you.
Regards,
ChuckB
Powered by vBulletin® Version 4.2.0 Copyright © 2013 vBulletin Solutions, Inc. All rights reserved.