image
image

Go Back   macosx.com > Design, Media, Programming & Scripting > Software Programming & Web Scripting

Reply
 
LinkBack Thread Tools
  #1  
Old April 17th, 2003, 04:04 AM
profx's Avatar
ill never 4get watsisname
 
Join Date: May 2001
Location: Auckland New Zealand
Posts: 386
Thanks: 0
Thanked 1 Time in 1 Post
profx is on a distinguished road
Question C /C++ and OpenGL

Hi,

I am doing a Computer graphics course at university. We have to use micro$oft .net to develop our assignments. But we use no low level (hardware dependant) c or c++ commands.

How would i go about changing the source of the assignment so it uses the mac osx GL, GLU and GLUT librarys?

here is the source provided by the lecturer http://www.cs.auckland.ac.nz/compsci...ss2Sources.zip

Can anyone help me to get this running on my mac?

Any help appreciated!! Save me a trip into uni so i can use the lab computers!
__________________
| PowerBook G4 550 - 10.4 - 512Mb - 20Gb | 30Gb iPod Photo | 40x12x48 Fantom Drives CDRW (firewire) | Logitech Cordless Mouse MX700 | xBox with XBMC for movies and music in the lounge
Reply With Quote
  #2  
Old April 17th, 2003, 01:31 PM
Captain Code's Avatar
Moderator
 
Join Date: Aug 2001
Location: Ontario, Canada
Posts: 3,119
Thanks: 0
Thanked 8 Times in 1 Post
Captain Code will become famous soon enough
You will need the developer tools installed, and in your project you will need to link to the GLUT framework which is installed at
/System/Library/Frameworks/GLUT.framework/
glut.h is at
/System/Library/Frameworks/GLUT.framework/Versions/A/Headers/glut.h
If you don't have that framework already listed, I think there's a way to add a new framework into the project and just tell it the path of the framework.

I *think* the path for the opengl headers is already included in your project, but if not, you might have to do something similar to the above to link to the opengl framework.
__________________
MacBook Pro 2.16GHz Core2Duo 3GB RAM, G4 1.4GHz OSX Tiger 1.25GB RAM, Dual 2GHz G5 OSX Tiger 2GB RAM (freakin shweet)
Athlon 64 Windoze XP for school work (programming) 1GB RAM
dferns@macosx.com
Reply With Quote
  #3  
Old April 17th, 2003, 08:37 PM
profx's Avatar
ill never 4get watsisname
 
Join Date: May 2001
Location: Auckland New Zealand
Posts: 386
Thanks: 0
Thanked 1 Time in 1 Post
profx is on a distinguished road
I have all the developer tools installed, im just not sure how to get the source to compile properly in project builder do i create a c/c++ tool or what?

Thanks for the reply
__________________
| PowerBook G4 550 - 10.4 - 512Mb - 20Gb | 30Gb iPod Photo | 40x12x48 Fantom Drives CDRW (firewire) | Logitech Cordless Mouse MX700 | xBox with XBMC for movies and music in the lounge
Reply With Quote
  #4  
Old April 17th, 2003, 09:38 PM
Captain Code's Avatar
Moderator
 
Join Date: Aug 2001
Location: Ontario, Canada
Posts: 3,119
Thanks: 0
Thanked 8 Times in 1 Post
Captain Code will become famous soon enough
Yes, a C++ tool is what you want to create since it's a command line program.
__________________
MacBook Pro 2.16GHz Core2Duo 3GB RAM, G4 1.4GHz OSX Tiger 1.25GB RAM, Dual 2GHz G5 OSX Tiger 2GB RAM (freakin shweet)
Athlon 64 Windoze XP for school work (programming) 1GB RAM
dferns@macosx.com
Reply With Quote
  #5  
Old April 20th, 2003, 06:56 AM
profx's Avatar
ill never 4get watsisname
 
Join Date: May 2001
Location: Auckland New Zealand
Posts: 386
Thanks: 0
Thanked 1 Time in 1 Post
profx is on a distinguished road
Ok

so what are the .h file includes called in Mac OS X

for windows:
Code:
#include windows.h
#include gl/gl.h
#include gl/glu.h
#include gl/glut.h
those all have angle brackets around them but this forum wont display them ... argh


but for mac??

once i have these i think i will be set


ALL help appeciated!!
__________________
| PowerBook G4 550 - 10.4 - 512Mb - 20Gb | 30Gb iPod Photo | 40x12x48 Fantom Drives CDRW (firewire) | Logitech Cordless Mouse MX700 | xBox with XBMC for movies and music in the lounge

Last edited by profx; April 20th, 2003 at 07:03 AM.
Reply With Quote
  #6  
Old April 20th, 2003, 05:57 PM
Captain Code's Avatar
Moderator
 
Join Date: Aug 2001
Location: Ontario, Canada
Posts: 3,119
Thanks: 0
Thanked 8 Times in 1 Post
Captain Code will become famous soon enough
I think the OpenGL headers are in the same location, and the GLUT ones are at GLUT/glut.h
__________________
MacBook Pro 2.16GHz Core2Duo 3GB RAM, G4 1.4GHz OSX Tiger 1.25GB RAM, Dual 2GHz G5 OSX Tiger 2GB RAM (freakin shweet)
Athlon 64 Windoze XP for school work (programming) 1GB RAM
dferns@macosx.com
Reply With Quote
  #7  
Old April 21st, 2003, 11:57 AM
Registered User
 
Join Date: Jul 2002
Posts: 59
Thanks: 0
Thanked 0 Times in 0 Posts
r4bid is on a distinguished road
http://nehe.gamedev.net/data/lessons...?lesson=MacOSX

I think that should help you out.
Reply With Quote
  #8  
Old April 22nd, 2003, 07:15 PM
PowerMacX's Avatar
Registered User
 
Join Date: Apr 2002
Location: Buenos Aires, Argentina
Posts: 29
Thanks: 0
Thanked 0 Times in 0 Posts
PowerMacX is on a distinguished road
windows.h -> delete this line
gl/gl.h -> OpenGL/gl.h
gl/glu.h -> OpenGL/glu.h
gl/glut.h -> GLUT/glut.h

Also, glut.h already includes gl.h & glu.h so you could delete those lines too.
Reply With Quote
Reply

Bookmarks

Thread Tools

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
Trackbacks are Off
Pingbacks are Off
Refbacks are Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
b85 and OpenGL theNonsuch Mac OS X System & Mac Software 0 October 5th, 2003 01:05 PM
configure.guess and configure.sub + Xdarwin + OpenGL DarkPulse Unix & X11 0 November 29th, 2002 10:46 PM
Anybody using Codewarrior 8 and OpenGL konan Software Programming & Web Scripting 2 October 23rd, 2002 01:34 PM
DVD Playback messes up OpenGL screensaver Dradts Mac OS X System & Mac Software 6 January 14th, 2002 04:10 PM
"Rev. A" iMac w/ GameWizard, no OpenGL! kommakazi Hardware & Peripherals 1 January 13th, 2002 10:11 AM


All times are GMT -5. The time now is 11:58 PM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.3.2
Copyright 2000-2010 DigitalCrowd, Inc.