OpenGL sites

Member
Posts: 64
Joined: 2005.06
Post: #1
Simple question; any good sites for learning OpenGL for Cocoa(Obj-C)?

...and I don't want the standard NeHe respone either; the NeHe site in itself is a very good site, but the Cocoa versions of their projects are completely different entities. There always seems to be a lot of extra code stuffed in for the sake of being stuffed in, there are no comments to explain what any of the code does (and that's a problem considering none of the code is the standard code NeHe gives), and there seem to be odd lines of code (i.e. Many If statements all huddled together, with maybe only one or two with brackets to define the statement.)

If there's something I'm missing here, feel free to point it out, but at the moment, NeHe is about as helpful as a smoking monkey, and while it may be neat, a smoking monkey is not what's needed.
Quote this message in a reply
Luminary
Posts: 5,143
Joined: 2002.04
Post: #2
OpenGL and Cocoa are unrelated.

Use NeHe to learn OpenGL
Use Apple's tutorials to learn Cocoa
Use Apple's simple Cocoa/OpenGL sample to learn how to put the two together.
Quote this message in a reply
ThrottleMonkey
Unregistered
 
Post: #3
Smoking monkeys are cool! They're usually the product of too much throttle! Grin

Here's a site that was shown to me and it helped TONS. If you look through my thread "Getting Started with OpenGL - Mac" only a few threads below this one, you'll see how everyone helped me out.

This is a link to Apple's "Getting started in OpenGL with Cocoa" help files:

http://developer.apple.com/techpubs/maco...ion_1.html

Hope this helps you like it did me.
Quote this message in a reply
Feanor
Unregistered
 
Post: #4
There is only one site with regular content about both Cocoa and OpenGL -- this one. And it's all in response to questions, so ask away. OSC, GoodDoug, henryj and many others have lots of insight. I even know a couple of things. Rolleyes

I cannot see why you have complaints about Bryan Blackburn's NeHe Cocoa ports. I think they are good examples, but that's just me. The only extra stuff they add that I have noticed is for setting up a proper application environment, with event management and the like.

Instead of considering OpenGL and Cocoa in their full glories, why not tell us what you want to accomplish? I myself prefer to first consider the requirements of the software, and then choose the technological solution second.
Quote this message in a reply
Founder
Posts: 1,139
Joined: 2002.04
Post: #5
Good one Feanor,

Ah there IS NeHeX, but we need to get together to lend a hand there.

Carlos A. Camacho,
Founder
iDevGames
Quote this message in a reply
Member
Posts: 469
Joined: 2002.10
Post: #6
The thing about OpenGL in Cocoa is the evil details... stupid little things like having to call (clearDrawable),(setView) in the update method of an OpenGLView. Little evil things that are blatantly unpolished interms of apple work. I keep hitting them while developing CocoaBlitz. I should start an OpenGL in Cocoa website... So much to do, so little time...

---Kelvin--
15.4" MacBook Pro revA
1.83GHz/2GB/250GB
Quote this message in a reply
Feanor
Unregistered
 
Post: #7
Quote:Originally posted by kelvin
The thing about OpenGL in Cocoa is the evil details... stupid little things like having to call (clearDrawable),(setView) in the update method of an OpenGLView. Little evil things that are blatantly unpolished interms of apple work. I keep hitting them while developing CocoaBlitz. I should start an OpenGL in Cocoa website... So much to do, so little time...

I have only ever had to clear the drawable when switching between windowed and fullscreen. If you don't do that, it isn't an issue. And you don't have to use setView at all if you subclass NSOpenGLView -- it does it automatically when you initialize view. CocoaBlitz uses fullscreen, so I can see this would come up for you, but since fullscreen requires a separate context, some management seems inevitable, IMHO.
Quote this message in a reply
Post Reply