Advertisement

Cross platform development

Started by November 05, 2003 11:26 AM
6 comments, last by James Trotter 21 years, 4 months ago
Hey. So I want to develop games that will run on both Windows and Linux. I''ve heard a few people recommending SDL. But what exactly is it SDL does? Will it make a window for me, and let me do the rest, or is there more? Any other things anyone would like to recommend? I''m open to suggestions!
SDL does everything you could want it to, pretty much.

from libsdl.org:

Simple DirectMedia Layer is a cross-platform multimedia library designed to provide access to audio, keyboard, mouse, joystick, 3D hardware via OpenGL, and 2D video framebuffer.

Yes it does handle window opening.

Myself i use it for input and window handling. I'll be using it for endian independance soon.

I've found DevIL very useful for cross platform image loading.

edit: forgot to close link tag

If I remember rightly, I used the NeHe SDL ports as a basis, then kept on modifying until it was what I wanted.

[edited by - mrbastard on November 5, 2003 12:37:11 PM]
[size="1"]
Advertisement
SDL will handle a lot of functions for you, it really depends what you want it to handle.

Out of the box as it were, it gives you Video, Audio and Event tools. Other SDL based libraries offer network layers and advanced audio visual handling (MP3 playing etc).

Might I suggest you take a look at the documentation on:
www.libsdl.org

Its quite comprehensive and very easy to read.

Cheers,

MrChris
I wrote a small "setup" tutorial on getting started on SDL+OpenGL if interested, its on my site (check sig), this is version 0.1 because I have to add the "compiling with the use of makefiles" part, I am planning on writting a whole bunch more tutorials (and host submited ones), but right now I am just starting the site, and working on other stuff.

Cheers!

Aeon Games
quote:
Original post by MrChris
Out of the box as it were, it gives you Video, Audio and Event tools. Other SDL based libraries offer network layers and advanced audio visual handling (MP3 playing etc).



Out of curiosity, do you have to pay royalties to use the MP3 format, in comercial applications, if you ise SDL for audio?
I am a big fan of SDL, used it for quite a while until I started a turn based engine where I wanted a flexible GUI. SDL doesn''t provide such things unless you get another library to support it and even then you have to make sure that it supports OpenGL correctly.

So with that in mind I landed on ClanLib. Not only does it does just about everything SDL does, it also has its own GUI stuff.

Just another alternative.

Clutch
Advertisement
quote:
Original post by James Trotter
quote:
Original post by MrChris
Out of the box as it were, it gives you Video, Audio and Event tools. Other SDL based libraries offer network layers and advanced audio visual handling (MP3 playing etc).



Out of curiosity, do you have to pay royalties to use the MP3 format, in comercial applications, if you ise SDL for audio?


Presumably... I''m not developing a commercial program though so I''m not paying it too much thought - if something does come up I should be able to rebuild the music module fairly quickly to use OGG (would be more of a pain to convert the MP3''s!)

ok, thanks people!

I''ve installed SDL and Mesa, and I''m gonna start developing as soon as I can ...

I might have a look at Clanlib if I need it sometime... thanks clutch, It''s good to know what alternatives you have!

This topic is closed to new replies.

Advertisement