could u please explain more? because i am just start learning OpenGL. Thanks alot.
Main Topics
Browse All Topicshi all,
I try to draw poly-line when user clicks on windows. however, i have this error
"GLUT: Warning in C:\OPENGL\Debug\Cpp1.exe: The following is a new check for GLUT
3.0; update your code.
GLUT: Fatal Error in C:\OPENGL\Debug\Cpp1.exe: redisplay needed for window 1, bu
t no display callback.
Press any key to continue"
please tell me what i did wrong. Thanks a lot.
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
GL_LINE_STRIP makes noit much sense, since you have only 2 vertices, you can use GL_LINES, but thats not the problem, its should work anyway. I check your code here, gonna be back in a sec.
Meanwhile, i recommend you reding the OpebGL-tutorials at nehe. They are very good and ever everything from the basics to advanced technics.
http://nehe.gamedev.net/
start here:
http://nehe.gamedev.net/da
well, i want a line to be draw whenever a user click on the window. Honestly to say to borrow OPENGL BIBLE, and also print tutorial from nehe, and computer graphic with openGL.while reading, i want to do some programs to gain experience.
After to make this program works, i will find a way to avoid global variable and extend more features :)
oh ike,
my purpose is different. For example, when user click at A, then click at B-> u will see a line between AB. Now user click at C -> u will see another line between BC. User click at D, u will see a line between CD.... it keeps going until user terminate program.
Somehow when i copy from Visual C++ 6.0 and paste here, indentation is screwup. hihi.
>> For example, when user click at A, then click at B-> u will see a line between AB. Now user click at C -> u will see another line between BC. User click at D, u will see a line between CD.... it keeps going until user terminate program.
I got that, but you have to make sure ViewportXFirst etc. are either
a) properly initialized or
b) are not rendered as long as the user did not click the mouse
But thats completely another story. This q was about "draw line" which is solved eh ;)
Hey valleytech,
Thanks for accepting the answer. I wonder, however, why you gave a B-grade. Are you not satisfied with the solution?
I copied this text from PenguinMod-Moderator, its saying:
"Please review our grading tips at http://www.experts-exchang
ike
I put a community-request here, asking to reopen the question:
http://www.experts-exchang
Business Accounts
Answer for Membership
by: ikeworkPosted on 2009-08-28 at 01:12:21ID: 25205700
Hi valleytech
You have to pass a render-function-callback to glut with:
glutDisplayFunc
You commented this line out.
ike