Archived

This topic is now archived and is closed to further replies.

Allegro or SDL?

This topic is 4994 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

not having used Allegro, i can only vote for SDL. I also found out that you can use SDL as a base for windowing and event handling if you move on to OpenGL. so... yeah, SDL.

Share this post


Link to post
Share on other sites
I have also not used allegro, but I have used SDL and I am very pleased with it, so I didn't even bother to check out allegro.

My bet is you'll enjoy it too, so I would start with that, learn from a few examples, and if you hate it, then try allegro.

Also, there is a free book you can find online 'Programming Linux Games' (don't have link now, but I posted it in a very recent SDL thrad)

Programming Linux Games <-- here it is... Granted, the book covers linux, but SDL is cross platform, so the SDL specific code works on windows too.

------------------------------------------------------------
// TODO: Insert clever comment here.

[edited by - drowner on March 25, 2004 3:43:25 AM]

Share this post


Link to post
Share on other sites
SDL does have th advantage of directly supporting OpenGL if you later decide to get into 3D programming as you can use SDL for windowing/input and OGL for graphics so my vote goes to SDL.

Share this post


Link to post
Share on other sites
Allegro also provides support for openGL via the add-on lib allegroGL.

I have used both in the past and IMO they both have there advantages. Allegro is slightly easier to pick up, has a friendly community (www.allegro.cc) and provides support for some things (such as datafiles and 3d software routines) that SDL doesn''t.

SDL on the other hand offers less in the core lib (and is consequently smaller, this is a good thing). There are plently of add-on libs for functionality that you may be missing. I haven''t had any experiance of the SDL forums so I can''t comment of them.

In the end its hourses for courses.

Share this post


Link to post
Share on other sites
I think i will directly into OpenGL, becuase I have had a little experiance with it before, nothing big, just making a 3d cube, and like 3d triangle. But then I move backwards and when back to the basic a C++ becuase I real skipped them just to get into 3d.

Share this post


Link to post
Share on other sites
I''d have to say, if you intend to use hardware rendering using OpenGL, you really want to use SDL.

SDL and Allegro do slightly different things.

SDL -> Provides basic support for setting up drawing surfaces etc, in a platform independent and fairly sane way. Also provides input, and various other things (like task-switching handling for windows etc)

Allegro -> Mostly provides quite a rich library for *Software* rendering. If you intend to use software rendering, Allegro is pretty good. Its routines aren''t the fastest, but they are very easy to use (and modern hardware is pretty fast, even for software rendering). Allegro also provides input handling, some (software) 3d routines, a simple GUI (Aimed at games *not* general purpose apps), and a few other things.

Allegro is a "Bigger" library, and from my experience, generally buggier. But it does a lot more and is easy to use, especially for game programming newbies.

SDL has a bunch of associated libraries like SDL_image (loads PNG, Jpeg into SDL surfaces including getting them into OpenGL textures pretty easily).

Allegro has some add-on libraries, including AllegGL, which combines openGL and Allegro, but my experience shows it''s patchy, and potentially suffers from performance problems (Not if you only use it for openGL, if you mix Allegro software rendering functions too).

AllegGL shows quite a lot of promise, as you can do potentially advanced / clever stuff (Allegro software rendering into openGL textures, then render those using opengl hardware on to the accumulation buffer, potentially in 3d, which should be quite cool)

Mark

Share this post


Link to post
Share on other sites
If anyone has any 2D Allegro vs SDL vs Anything Else benchmarks, i''d be interested. I''d like to up my 2D framerate if possible and am just curious which lib has faster straight-up image blitting.

Share this post


Link to post
Share on other sites

This topic is 4994 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Guest
This topic is now closed to further replies.