🎉 Celebrating 25 Years of GameDev.net! 🎉

Not many can claim 25 years on the Internet! Join us in celebrating this milestone. Learn more about our history, and thank you for being a part of our community!

Carbon application and XCode 3+.

Started by
4 comments, last by Casual 13 years, 3 months ago
How to create carbon application using XCode version 3+ (last version before 4)?
Is it possible or i must use older versions?
Advertisement
Apple removed the Carbon application templates in Xcode 3.2. If you have a Mac OS X 10.5 install disc, you can install Xcode from the disc. That version of Xcode has Carbon application templates. You can also download Xcode 3.1 from connect.apple.com.
Mark Szymczyk
Author of Mac Game Programming and Xcode Tools Sensei
http://www.meandmark.com
Thank you, szymczyk.

Carbon API was only way to write applications on c++. Isn't it?

Suppose we have some Windows OpenGL applications written on C++.
What is the best way to port it on MAC OS?

Few years ago i solved this problem using Carbon API.
And everything was cool until the day when i needed to make some changes in these applications.

If i understand correctly Cocoa uses Objective-C but rewriting all aplications from c++ to objective-c is too hard.....
XCode supports Obj-C++ as well. It is a mixture of Obj-C and C++. Its the way I use just at the moment, because my engine is written in C++. Go into the target's Build settings, search for "language" (will bring section "GCC 4.x - Language") and see the "Compile Sources As" entry. There you can either set "According to File Type" and use e.g. *.mm for Obj-C++ files, or else set directly "Objective-C++". Then calling C++ from Obj-C and vice-versa is possible.

Carbon can AFAIK still be used but it is deprecated. Its dead was announced a long time ago. Today you should definitively use Cocao for windowing, and perhaps some of the Core services.

Suppose we have some Windows OpenGL applications written on C++.
What is the best way to port it on MAC OS?

I recommend using a cross-platform game library like SDL, Allegro, or SFML. Using one of these libraries would allow you to support Linux as well as Mac OS X. If you decide to use SDL, the following article may help you:


SDL and OpenGL
Mark Szymczyk
Author of Mac Game Programming and Xcode Tools Sensei
http://www.meandmark.com
Thank you for your answers. I'm decided to use SDL.
Thanks szymczyk for the excellent introduction aticle.

This topic is closed to new replies.

Advertisement