
Dialogs and buttons with a bit of GL thrown in
Hi Guys,
Does anyone have a Visual C++ 6 workspace they could send me that has a dialog with a GL viewport on it so that I can build it up into an application with buttons etc... ? :O)
I can''t find anywhere how to achieve this, only GL taking up the whole window in a dialog not created by Visual C++''s editor.
I''ve got my gl code to load and display what I need. I now just need to get it into a windows application window with buttons and sliders for controls.
Also if there''s anything on the web, could you point it out to me. Ta
Thanks for any help,
Jacca

Ha,
i am a newb opengl programmer.
but i have studied code in win32 programming that deals with this.
what you do is with wglCreateContext(), instead of using the hdc for the entire window as you would usally use in any other gl program.
you get the HDC to a control or area on the window where you only want the GL to appear.
You can do this with many things, you can have a button with an entire gl scene on it if you want to.
any control, just get the HDC to it, using
dc = GetDC(GetDlgItem(window, control));
and set it up after that as any other opengl program.
i think that is what i reemeber from it..
it should work.
but if you are stuck after you spend hours stressing over it.
go to planetsourcecode.com
and in C++ catagory, search for opengl
i think that is what it was.
what will come up is a window with 3 GL windows within in with a exit botton in the middle ..
if it is still there, you should be able to find it very easly.
i hope that helps you.
remeber you got to help me when i got my newb Opengl quetsion :0
i am a newb opengl programmer.
but i have studied code in win32 programming that deals with this.
what you do is with wglCreateContext(), instead of using the hdc for the entire window as you would usally use in any other gl program.
you get the HDC to a control or area on the window where you only want the GL to appear.
You can do this with many things, you can have a button with an entire gl scene on it if you want to.
any control, just get the HDC to it, using
dc = GetDC(GetDlgItem(window, control));
and set it up after that as any other opengl program.
i think that is what i reemeber from it..
it should work.
but if you are stuck after you spend hours stressing over it.
go to planetsourcecode.com
and in C++ catagory, search for opengl
i think that is what it was.
what will come up is a window with 3 GL windows within in with a exit botton in the middle ..
if it is still there, you should be able to find it very easly.
i hope that helps you.
remeber you got to help me when i got my newb Opengl quetsion :0
"What we do in life, echos in eternity" -- Gladiator
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement
Recommended Tutorials
Advertisement