OpenGL Setup Without GLUT
Yes, I know its been asked a thousand times, about three times by myself in the past, but I am still lost.
How do I set up OpenGL in Cocoa? NeHe and all other large resources only tell you how to do it using GLUT (which I don't like, so I don't want to use it), and the sources that don't use GLUT (Apple) aren't very good examples. Now, I do understand the very basics, such as setting up a pixel format, and such. However, I don't know all the steps I have to go through, and what steps I do know, I don't know the order, or everything about them.
I've spent most of today trying to piece it together myself with no luck, and on the net, I've found only bits and pieces here and there, that help me.
How do I set up OpenGL in Cocoa? NeHe and all other large resources only tell you how to do it using GLUT (which I don't like, so I don't want to use it), and the sources that don't use GLUT (Apple) aren't very good examples. Now, I do understand the very basics, such as setting up a pixel format, and such. However, I don't know all the steps I have to go through, and what steps I do know, I don't know the order, or everything about them.
I've spent most of today trying to piece it together myself with no luck, and on the net, I've found only bits and pieces here and there, that help me.
Just download Apple's Cocoa or Carbon OpenGL samples.
I also liked the Deep Cocoa site; that framework may not perform as well I'm told, but it does give you a nice way to handle events uniformly between windowed and full-screen.
If you have specific needs that those don't meet (sharing textures with multiple contexts, switchable between full-screen and windowed, etc.) post about it and someone can probably point you in the right direction.
I also liked the Deep Cocoa site; that framework may not perform as well I'm told, but it does give you a nice way to handle events uniformly between windowed and full-screen.
If you have specific needs that those don't meet (sharing textures with multiple contexts, switchable between full-screen and windowed, etc.) post about it and someone can probably point you in the right direction.
Measure twice, cut once, curse three or four times.
There is actually a tutorial at CocoaDevCentral on switching between windowed and fullscreen, and while it wasn't originally designed for games or OpenGL, it is actually one of the best examples I have found. Other than that, I just want to set up a standard OpenGL context.
subclass NSOpenGLView
use that and create a little view in your window in your nib
then code
use that and create a little view in your window in your nib
then code
Possibly Related Threads...
| Thread: | Author | Replies: | Views: | Last Post | |
| OpenGL Pixel Buffer Object setup issue | dotbianry | 2 | 1,101 |
Jan 6, 2013 11:03 AM Last Post: dotbianry |
|
| OpenGL ES2 matrix setup (humbly crawling back) | Fenris | 2 | 5,237 |
Aug 31, 2011 06:47 AM Last Post: Fenris |
|
| OpenGL and GLUT on MacOSX | Salvietta | 1 | 2,033 |
Sep 19, 2008 12:03 PM Last Post: OneSadCookie |
|
| Dealing with GLUT and OpenGL... | RingoEST | 10 | 4,933 |
Aug 16, 2008 12:24 AM Last Post: RingoEST |
|
| bug in OpenGL setup for NSOpenGL subclass (I think) | backslash | 2 | 3,269 |
Jul 18, 2007 01:10 PM Last Post: backslash |
|

