As you may know, I was researching of what is the best free library to teach game programming to high school student. And I suddenly stumbled upon this post, which the last comment gave a very good overview about the major libraries and which one to choose. I will quote it here, just in case the site will be down sometime in the future.
- SFML — the baby in the group, but potentially easiest to use from what I’ve read.
- SDL — the middle road. Very mature library, sensible, generally concise if a little arcane from time to time, and a very common choice. Setting up display formats can be a bit of a bastard, I’ve used lazyfoo’s tutorials to help on that front.
- Allegro — Geriatric, it’s been around since Atari ST days. For that reason, a lot of the 2D rendering code (which I think is only in Allegro 4) is pretty darn quick since the logic was built for much lower spec systems. I personally don’t find it very intuitive, even considering the documentation.
Considering OpenGL accelerates the 2D side of things these days, it’s not that important to have access to the fast software renderers that Allegro and SDL have (or had in earlier versions). However when I pick a library I focus on project maturity, user base and docs more than speed (so long as speed is reasonable), and I would say SDL and Allegro win on those fronts. SDL has also been to release triple AAA titles like Civ: Call to Power.
For you who wants some direct links, here are the direct links to each of the library’s overview:
- SFML – Features | Tutorials | Download
- SDL – Features | Tutorials | Download
- Allegro – Features | Tutorial | Download