Opinions: SDL vs SFML

Started by
4 comments, last by brent_w 15 years, 8 months ago
I'm in the early stages of a new project I originally planned to use SDL for. However, someone recently introduced me to SFML, and it appears to be very interesting. I'm not sure which library to go ahead with, so I'm curious to hear some opinions from people who have used the libraries before. What do you think of each libraries' implementation? Which is more user friendly? Which seems to have better performance? You know, stuff like that. Thanks in advance for your advice. Edit: Oh, and I know some of this information is covered in a thread by SFML's author on the SFML forums. But I thought it would be best to get opinions from an unbiased third party.
Advertisement
I have used both SDL and SFML and I would go for SFML. I like its design, it gives you everything you need in SDK, there are nice tutorials on the website and since rendering is done with OpenGL, it is MUCH faster than SDL.
Hey Brent.

I've started to use SFML myself. It's slightly more complicated than SDL, but the enhanced performance (I think. It automatically streams music files, so it helps load times, but I haven't measured to see how fast it is otherwise. It's at least as fast as SDL) and more features easily make up for it. The object-oriented design is nice as well, though I miss being able to blit to SDL_Surfaces (For instance, blitting each tile in a map to a surface and then simply blitting that surface to the screen. Does anyone know if this can be done in SFML? I haven't put much thought into it since I don't need it for my current project, but it'd be nice to know).

My biggest problem with SDL was that it couldn't do realtime image rotation; you either had to pre-rotate the images in the file, or download an add-on that I never managed to get working quite right, and even then it was too slow to do in realtime. SFML can do this easily, quickly, and much more smoothly than would have been possible with cached rotations in SDL.
though I miss being able to blit to SDL_Surfaces (For instance, blitting each tile in a map to a surface and then simply blitting that surface to the screen. Does anyone know if this can be done in SFML?

Not now but it's on the todo list so it will be possible in few time :D
Another vote for SFML here. The design of the library and provided documentation are excellent, and the small but growing community is generally pretty helpful; due to the small size of the userbase there's also still a good chance a a reply from the creator/maintainer of the library if you're having any issues. Performance is pretty good, the library doesn't seem to suffer from any major show-stopping bugs, and updated versions with bug-fixes and new features are being released pretty steadily.

- Jason Astle-Adams

Thanks for the replies.

I think I've decided to go ahead with SFML, if I can figure out why I can't get it to work properly in VS2008

This topic is closed to new replies.

Advertisement