PDA

View Full Version : How can I use glfunction...another application;Help!!!!!!!!



hcrogma
04-23-2003, 08:50 AM
I have written a programs with various butttons.

I am traying to use all the gl drawing function....to plot energy surfuces...but when I do so it said no window is active...However, when I do MoveTo,LineTo....I get a line in my window....A window comes up with the folow along with my window.;;

Glut: warning in (unamed) :glutDisplayFunc:no active...

I do not want to use gl window....Ineed to use my window....


Please help me....Thank you

shinpaughp
04-23-2003, 08:52 AM
Then don't use glut. You need to set up an OpenGL rendering context and make it current.

nexusone
04-23-2003, 09:21 AM
You can not mix GLUT and Windows API, GLUT is for stand alone appications with out windows specific functions like menu's and button's.

Go to a site like nehe.gamedev.net and look at how they setup gl in a windows specific type window.

Inside your window you will have to create a contex in which openGL can draw to.


Originally posted by hcrogma:
I have written a programs with various butttons.

I am traying to use all the gl drawing function....to plot energy surfuces...but when I do so it said no window is active...However, when I do MoveTo,LineTo....I get a line in my window....A window comes up with the folow along with my window.;;

Glut: warning in (unamed) :glutDisplayFunc:no active...

I do not want to use gl window....Ineed to use my window....


Please help me....Thank you