While I myself know C++ another developer, prefers C and
so we have decided to use C. The Mac developer site states that
Carbon is its API for C an Cocoa for C++ so we choose Carbon.
Our needs for a GUI are minimal . The application is essentially
a scripting language for mathematical graphics based on OpenGL.
So all we need is an OpenGL canvas (for 3D) and a native Canvas
for 2D. We would have used some middle ware like WxWidgets if
the GUI part was intensive. However since this is not the case
we wanted to keep dependencies to a bare minimum. This is also
the reason why we are avoiding things like Tcl/Tk. Code wise
this is not a large application so I am unsure if the
overhead of oject creation/destrustion is worth the benifits
of OOP. Though ofcourse we plan to keep our interfaces clean :).
There are other similar GUI based applications but only one I
am aware of that functions almost like a scripting language. It is
called Dynagraph and is based on the Xforms library. Hence
needs an Xserver running (see www.math.umbc.edu/~rouben/dynagraph)
What I am trying to do is reimplement Dynagraph using Win32/Carbon/Xlib
so that it runs using the native libraries making it easier
to install. Currently Dynagraph is a pain to install on windows
using Cygwin and I have not been able to try it on a Mac.
regards
b thomas
Post by Uli KustererPost by B ThomasCould you kindly point me to any good tutorial for programming
user interfaces and OpenGL applications for Mac OS X using C and
the Carbon API. I am not a Mac User but am planning on writing some code
for multiple platforms (including Mac).
Hi,
others have pointed out Carbon tutorials, but I thought I'd mention one
thing: If your main reason for Carbon is that you want to use C or C++,
you can also use Cocoa. MacOS X's GLUT implementation is written in
Cocoa, and Objective C is a real superset of C, and there's something
called "Objective C++" that lets you easily mix ObjC and C++ code in a
single file in a very natural way.
I'd generally recommend doing new development in Cocoa, especially if
you need a Mac GUI. Carbon is mainly good for doing low-level and
backend work, or if you need very fine file system manipulation.
Cheers,
-- Uli Kusterer
http://www.zathras.de