Sign in to follow this  
Mazer

Alternatives to SDL?

Recommended Posts

Hey, I'm working on making a game using SDL and OpenGL and recently began wondering if there are any other alternatives for my uses of SDL. Here's what: I use SDL for opening a window, getting keyboard input, and loading images, and I love that it's cross platform and requires very little effort on my part to get my game compiling under a different OS. However, I don't really like the license. Maybe I'm wrong and therefore making a complete ass of myself by posting this, but my understanding is that I have to provide the source code to my game wherever I'm distributing the game itself. Right? I think open source is cool, but should be optional. BUT, this isn't a discussion on open source software, I was just wondering if anybody knows of free [and cross-platform] libraries (under a license that won't require me to release my own source) for: -Opening Windows -Getting keyboard input (in a bool keys[] kind of way) Thanks for any help, -Nick

Share this post


Link to post
Share on other sites
The license only requires that the user can change the SDL-part of your game. If you use SDL as a .dll that is automatically fullfilled. You don't need to release the source of your game.

Share this post


Link to post
Share on other sites
Allegro?

To my knowledge, it only becomes a problem if you plan on selling your software that uses SDL. Details about the licensing are available on their website.

Quote:
To comply with this license, you must give prominent notice that you use the Simple DirectMedia Layer library, and that it is included under the terms of the LGPL license. You must include a copy of the LGPL license.
You must also do one of the following:

1. Include the source code for the version of SDL that you link with, as well as the full source or object code to your application so that the user can relink your application,
or
2. Include a written offer, valid for at least three years, to provide the materials listed in option 1, charging no more than the cost of providing this distribution,
or
3. Make the materials listed in option 1 available from the same place that your application is available.

Share this post


Link to post
Share on other sites
Quote:
Original post by Trap
The license only requires that the user can change the SDL-part of your game. If you use SDL as a .dll that is automatically fullfilled. You don't need to release the source of your game.

That's what I thought at first, but I became confused about it after reading this bit:
Quote:
... as well as the full source or object code to your application so that the user can relink your application,...

What does that mean? Just give people all the lines in which I call SDL functions?

Share this post


Link to post
Share on other sites
Quote:
... as well as the full source or object code to your application so that the user can relink your application,...

Your executable is object code. relinking happens every time a .dll is loaded.

Share this post


Link to post
Share on other sites
Basically, using it as a .dll fulfills all those requirements of the license. If it required more, I don't think commercial cross-platform games would use it. As long as you feel it works for you, go ahead and use it.

Share this post


Link to post
Share on other sites
Jolly good.

I guess I'll just continue with SDL then, but I'll be sure to look into GLFW too. Thanks, everybody, for the quick and informative responses. I appreciate the help!

-Nick

Share this post


Link to post
Share on other sites
Quote:
Original post by Boder
You might also check out Allegro, not sure about the license though.

Allegro is giftware in every sense; basically license-free. The developers only encourage that you give something back to the community. :)

Just so you know, anyway. Sounds like SDL will still work out fine for you.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this