Original Post
I have been trying to learn object oriented programming in c plusplus I seem to do ok with console programs, but I can't seem to make anything work when I try to use it with glut/Open GL. I can use glut and open GL by themselves ok although I still have a lot to learn about it. Below is the code where I am getting 2 compiler errors. I have added comments where I am getting the errors. I can't see any problem but it won't compile. It is always possible that even when I get past that, more errors could pop up. Much Thanks up front to anyone who will help me with this. L.J. Bush
void circle::draw(){
int i;
glPushMatrix();
glEnable(GL_LINE_SMOOTH);
glLineWidth(2);
glBegin(GL_LINE_LOOP);
for(i=0; i <= pnts; i++){
float angle = 2 * PI * 0.5 / pnts; // expected primary-expression before '=' token glNormal3f(cos(angle), 0, -sin(angle));
angle = 2*PI * i / pnts; // expected primary-expression before '=' token
glVertex3f(Cx,Cy * -cos(angle),Cz * sin(angle));
}
glEnd();
glPopMatrix();
}