To swing a swing

hello sir , now i am doing a mini project for my 6th sem on opengl,
and i did my own project, in my project i drawn one person standing
on a road, and beside him one swing is tightened to the tree, and i
want to swing that swing, but i am getting only the swinging of that
swing and all pictures are disappearing, so i need help from you
such that i want to swing the swing only and all pictures should
constant…
please will you help me soon within two days i want, kindly requesting you,

hello sir , now i am doing a mini project for my 6th sem on opengl,
and i did my own project, in my project i drawn one person standing
on a road, and beside him one swing is tightened to the tree, and i
want to swing that swing, but i am getting only the swinging of that
swing and all pictures are disappearing, so i need help from you
such that i want to swing the swing only and all pictures should
constant…
please will you help me soon within two days i want, kindly requesting you,

Push model-view matrix on the stack, do the transformation, and then pop it up. Don’t forget to reset model-view at the beginning of draw function.

first thanks for your reply,
please can you explain me bit clearly,either with code or with example,please

If you have an openGL course at this semester, you should remember this basic things.
Well, in short, if you are using fixed functionality just call glPushMatrix(), then do all transformations needed to display swing in a proper position, and then call glPopMatrix().

thanks, now i got the swinging of that swing in the display window, when i pressed the key to perform the swinging operation the swing is swinging but the swing is buffering and other function keys are not working… till now i used glutSwapBuffers() and also glClear(GL_COLOR_BUFFER_BIT) But samething happening, i tried lot to avoid that buffering or flickering but no use, please help me

please reply me soon

Sir,how to stop buffering of that swing,till now i used glClear(GL_COLOR_BUFFER_BIT); and glutSwapBuffers
then also buffering is there so what to do, please reply me soon

Sir,how to stop buffering of that swing,till now i used glClear(GL_COLOR_BUFFER_BIT); and glutSwapBuffers
then also buffering is there so what to do, please reply me soon

What buffering are you talking about?
If you are creating a 3D scene, activate depth test with glEnable(GL_DEPTH_TEST), and clear depth buffer before each drawing with glClear(GL_COLOR_BUFFER_BIT|GL_DEPTH_BUFFER_BIT).

no it is not a 3d scene ,its just a swing drawn using glVertex(GL_POLYGON); which is tightened to the tree, i done swinging of that swing its coming but it is buffring

Please, give better description, or attach a screen-shoot.

I got that swinging,sir now i want how to avoid flickering of an object drawn using glBegin(GL_POLYGON)