Welcome, Unregistered.

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Reply
Old 10-Aug-2012, 16:37   #1
Scott_Arm
Regular
 
Join Date: Jun 2004
Posts: 6,814
Default OpenGL C++ in OSX

I'm feeling like hobbying with OpenGL, just to learn how it works and toy around. Nothing serious. I primarily use OSX, though I am setup to boot into Windows if need be. The thing is, I've never really used Objective-C, and don't particularly want to learn it. I'd rather stick with C/C++, which I already know. It seems like I'd have to use GLUT, if I want to use C++. Is that true, or not true? Is GLUT a good place to start when learning? I've heard it has some limitations, but I'm not familiar with what those limitations would be.
Scott_Arm is offline   Reply With Quote
Old 14-Aug-2012, 12:44   #2
idsn6
Member
 
Join Date: Apr 2006
Posts: 300
Default

GLUT is not necessary for C++, nor is it a good entry point for modern OpenGL. Take one of Apple's sample OpenGL projects and gut the rendering loop, then replace it with your code. You can combine pure C or C++ with Cocoa just fine.
idsn6 is offline   Reply With Quote
Old 14-Aug-2012, 15:24   #3
Scott_Arm
Regular
 
Join Date: Jun 2004
Posts: 6,814
Default

Thanks. I've been reading this online book, which uses GLUT (http://www.arcsynthesis.org/gltut). I'm thinking of following all of the tutorials, but doing them with Cocoa instead of GLUT. This book sticks to core profile, so there's none of the fixed-function deprecated stuff. Still seems pretty straightforward for learning the basics. I'll have to figure a few things out in terms of initializing things in OpenGL, but that should be fine. Good to know I can mix C/C++. I took a look at Objective-C once, but I found the syntax ugly, and then I just got bored of the idea of learning it.
Scott_Arm is offline   Reply With Quote
Old 17-Aug-2012, 02:49   #4
zed
Member
 
Join Date: Dec 2005
Posts: 2,089
Default

no you dont need glut at all. I dont use it
u do need to do a bit of obj-c, though not much. prolly ~2% of my code is obj-c the rest is my hybrid c/c++.
I agree obj-c has horrible syntax
__________________
stalk me on twitter
zed is offline   Reply With Quote

Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 15:45.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.