View Full Version : New to OpenGl
06-27-2001, 09:07 AM
Hi. I'm new both to this board and (relatively) programming in C++. http://www.opengl.org/discussion_boards/ubb/redface.gif
I'm curious whether anyone can recommend a resource, book, etc., to get me started on OpenGL? How thorough a knowledge-base would you say I'd need, Beginning, Intermediate, or Advanced?
Any help would be greatly appreciated.
[This message has been edited by riskbreakerVS (edited 06-27-2001).]
I'm new to openGL too... what I suggest is you check out the tutorials on http://nehe.gamedev.net, download the source code (most comes in Project Builder format for OS X) and check out the books he recommends....
i'm pretty sure that to do opengl programming with osx you've got to use objective-c.
definitely not c++.
you might pick up the learning cocoa book from oreilly. http://www.oreilly.com/catalog/learncocoa/
and for opengl, you'll want the redbook (opengl 1.2 programming guide, 3rd ed, by woo, neider, et al)
opengl is pretty simple. the key is realizing that "opengl" in your program represents a type of drawing machine with a definite state (like some class object with a bunch of data members with assigned values). once you set up it's state (as in, "whenever you draw lines, make 'em this thick, and make points this thick, and when you draw triangles, make 'em this color and shade 'em like so-and-so, etc..) you just hand it values of points in 3d space and tell "it" what you mean by those points (as in, with the next 3 points (so that's nine numbers all together) i mean a triangle).
i think you'd want to use project builder to write and compile your ogl programs.
06-28-2001, 06:42 PM
OK. First, thanks to both who have replied so far (Nephilite and jmg). I found the website very instructive.
I have a question. Two, actually. What is Objective C? Like I said, I'm very new to programming in these more mainstream languages (to be honest, I thought that C++ basically was objective C). Second, I'm still running OS9, but I plan to upgrade when more software comes out that is Carbon native. Is there a problem with C++ and OS X? Or is the problem more with OpenGL, C++, and OS X? If there is, would you please give me some basic info on it (or a link to a site)?
Thanks again! http://www.opengl.org/discussion_boards/ubb/smile.gif
06-28-2001, 11:48 PM
OpenGL is a C API, but there are bindings for Java, Fortran and a bunch of other languages. You should have no problem at all using OpenGL and C++, no matter what OS you run on. To learn OpenGL programming, get The Red Book (OpenGL Programming Guide), a good book on C++, and a math book covering linear algebra. Something on 3d graphics like Real Time Rendering would probably also be a good idea.
osX is supposed to have really good support (that is, a good implementation) of the most recent opengl 1.2.
objective c is not c++. its notation is different but supposedly easy to get used to if you know c, and also supposedly simpler than c++. recall, apple bought NeXT which used objective-c. learning cocoa would explain most of the details of obj-c.
on any other operating system you'd write c++ programs which have objects whose methods make opengl calls (opengl is a bunch of c functions---it's a c api as harsman says).
the way i understand osx (and i don't understand much) is that if you want to use their object-oriented windowing api (cocoa), you've got to use objective-c to do it. i figured that the compiler that project builder uses is for objective-c or ansi c. if you give it c++ it doesn't know what to do with it... tho, since osx is based on darwin, i'm guessing you could wire in any compiler you like... wouldn't have a clue how do this tho.
if you're interested in programming for the mac, upgrade to osx now. learn objective-c (it won't take long). learn how to use project builder (the ide that comes with osx).
Powered by vBulletin® Version 4.2.2 Copyright © 2015 vBulletin Solutions, Inc. All rights reserved.