OpenGL Blues
What those tutorials were probably getting at though is that there are a couple of ways to use Opengl. Typically, if you're using a Win32 app, you're going to be creating your window and doing all your setup yourself. If you're going to be using a console app, the way to go is probably GLUT, the GL Utility Toolkit(I think). This is just a library that makes it a lot easier to initialize OpenGL and get yourself up and running. It's commonly used for demos, but I don't think too many commercial apps use it, as it's not installed in Windows by default.
Hope this was helpful
Jonathan
Well, I suppose I should stop typing now.
-Nick
In Tribes (and Tribes2) we used a console app because we wanted to use the same executable for the dedicated server as well as the client. In client mode, it just created a window and used wglCreateContext to "bind" OpenGl to that window DC (just like you would for a win32 app). In dedicated mode it does not create a window, avoiding a ton of windows/opengl overhead, and simply echos info to the console.
--Rick
TribesPlayers.com
You might want to check out GLUI:
GLUI is a GLUT-based C++ user interface library which provides controls such as buttons, checkboxes, radio buttons, and spinners to OpenGL applications. It is window-system independent, relying on
GLUT to handle all system-dependent issues, such as window and mouse management. Features of the GLUI User Interface Library include:
- Complete integration with GLUT toolkit
- Simple creation of a new user interface window with a single line of code
- Support for multiple user interface windows
- Standard user interface controls such as:
- Buttons
- Checkboxes for boolean variables
- Radio Buttons for mutually-exclusive options
- Editable text boxes for inputting text, integers, and floating-point values
- Spinners for interactively manipulating integer and floating-point values
- Static text fields
- Panels for grouping sets of controls
- Separator lines to help visually organize groups of controls
- Controls can generate callbacks when their values change
- Variables can be linked to controls and automatically updated when the value of the control changes ("live variables")
- Controls can be automatically synchronized to reflect changes in live variables
- Controls can trigger GLUT redisplay events when their values change
- Layout and sizing of controls is automatic
- Controls can be grouped into columns
- User can cycle through controls using Tab key
I never used it before so I can't recomend it from experience, I ran across it the other day while looking for a cross platform GUI.
Also, if you were to write your program as a console app I would think it would be easier to port to Linix if you ever decided to do so.
"You know you're obsessed with computer graphics when you're outside and you look up at the trees and think, "Wow! That's spectacular resolution!""