Integrating SDL with GUI toolkits?

Hello, I am interested in developing an application that interfaces to
a joystick. It will run on OS X and Linux, using SDL for joystick
handling and using Cocoa (on OS X) or GTK (on Linux) for the GUI.
What’s the best way to do this? Do I need to start each event loop in
a separate thread? Any advice or sample code would be much
appreciated, especially if there’s a painless way to do this
integration while using whizzy GUI-tools like interface/project builder
and/or glade for interface design. :slight_smile:

best,
wb

For coding the GUI i would use FLTK :slight_smile:
It has a nice GUI Designer ( FLUID ).

CU

“Will Benton” schrieb im Newsbeitrag news:mailman.1036355222.15297.sdl at libsdl.org…> Hello, I am interested in developing an application that interfaces to

a joystick. It will run on OS X and Linux, using SDL for joystick
handling and using Cocoa (on OS X) or GTK (on Linux) for the GUI.
What’s the best way to do this? Do I need to start each event loop in
a separate thread? Any advice or sample code would be much
appreciated, especially if there’s a painless way to do this
integration while using whizzy GUI-tools like interface/project builder
and/or glade for interface design. :slight_smile:

best,
wb

For coding the GUI i would use FLTK :slight_smile:
It has a nice GUI Designer ( FLUID ).

OK, since that doesn’t answer my question, I’ll ask another. :slight_smile:

Specifically, what do I need to do to have an OSX app that has a Cocoa
GUI, preferably built in project builder? The SDLMain.m is pretty
confusing to me, but I haven’t looked at it too carefully. Is it
enough to fork off another thread for SDL_Init() and the SDL event loop?

In general, can I have an SDL event loop in a non-main thread? A quick
test program under Darwin and Linux seems to confirm this, but I wanted
to make sure.

best,
wb