How to draw point by point

Hello,
I am going to draw 5 segments in my program. But I want to draw them one by one, this means after drawing the first line segment, the second segment will be appeared on the screen after a few seconds and vice versa. How to do that ? Any source code can provide for reference? Thanks for giving help !

What u want to do is Animation.
For animation u need Timer

If u are using GLUT, Use glutTimerFunc
or Call glutGet(GLUT_ELAPSED_TIME) every time
u display some thing. These things basically to keep track of time.

One ur program is ‘time-aware’, it can decide, what to draw and when.

  • Chetan