The following is the code for drawing a Electric pole in a scene.
While I execute the pole always stands little above the ground position. It is not fixed on the ground. What may be problem
Well, I’m going to assume you’re not drawing the ground at Y=0…which could be a problem…but there’s no way to tell as you’ve provided about as little information as anyone could humanly provide…=P (Can we see some more code?)
I have a more detailed code.First I am adding a Ground in the scene. On the top of it I am drawing the ELectric pole.
glColor3f(0.6f, 0.6f, 0.9f);
/* All Tex coordinate were added */
glVertex3f(-100.0f, 0.0f, -100.0f);
glVertex3f(-100.0f, 0.0f, 100.0f);
glVertex3f( 100.0f, 0.0f, 100.0f);
glVertex3f( 100.0f, 0.0f, -100.0f);
if(l%2 == 0 && m%2 == 0)
already given above
What is this line intended to do?
That line would be the reason why the flag pole isn’t being attached to the ground.