Simple and Fast Multimedia Library
|Original author(s)||Laurent Gomila, and others|
2.4.2 / February 8, 2017
|Operating system||Linux, macOS, Windows, FreeBSD|
Simple and Fast Multimedia Library (SFML) is a cross-platform software development library designed to provide a simple application programming interface (API) to various multimedia components in computers. It is written in C++ with bindings available for C, Crystal, D, Euphoria, Go, Java, Julia, .NET, Nim, OCaml, Python, Ruby, and Rust. Experimental mobile ports were made available for Android and iOS with the release of SFML 2.2.
SFML handles creating and input to windows, and creating and managing OpenGL contexts. It also provides a graphics module for simple hardware acceleration of 2D computer graphics which includes text rendering using FreeType, an audio module that uses OpenAL and a networking module for basic Transmission Control Protocol (TCP) and User Datagram Protocol (UDP) communication.
SFML is free and open-source software provided under the terms of the zlib/png license. It is available on Windows, Linux, macOS and FreeBSD. First version 1.0 release was in July 2007, latest and current release v2.4.2 is from 8 February 2017.
SFML consists of various modules:
- System – vector and Unicode string classes, portable threading and timer facilities
- Window – window and input device management including support for joysticks, OpenGL context management
- Graphics – hardware acceleration of 2D graphics including sprites, polygons and text rendering
- Audio – hardware-accelerated spatialised audio playback and recording
- Network – TCP and UDP network sockets, data encapsulation facilities, HTTP and FTP classes
While the graphics module is one of the main features of SFML, developers who are interested in only creating an environment to program directly in OpenGL can do so by using the Window module on its own without the graphics module. Similarly, the other modules can also be used independently of each other, except for the System module which is used by all of the modules.
This table lists supported bindings for SFML as of 2017[update].
1 Official bindings
SFML provides the basic functions on which higher-level software can be built. Add-on libraries exist that provide added support for graphical user interfaces (GUIs), 2D lighting, particle systems and animation, video playback and tilemaps.
Reception and adoption
SFML is primarily used by hobbyist game developers, small independent video game developers, and startup companies consisting of several developers at most. Because SFML does not require writing large amounts of code, it has been adopted by many Ludum Dare participants also. Compared to older libraries such as Simple DirectMedia Layer (SDL) and Allegro, the SFML user base is relatively small but growing. As of 3 April 2017[update], its GitHub software repository has been starred by 3394 users.
Video game use examples
- Atom Zombie Smasher, real-time strategy game.
- Chesster, puzzle game.
- Cosmoscroll, free open-source space-based shoot 'em up game.
- Crea, moddable 2D sandbox game.
- HolySpirit, 3D isometric hack and slash game.
- Kroniax, minimalistic side-scroller, and the first SFML game for Android.
- M.A.R.S., multiplayer shoot 'em up game.
- Moonman, pixel art exploration sandbox game.
- Ovid The Owl, puzzle platform game.
- Project Black Sun, retro 2D side-scrolling video game.
- The Duke, action platform game.
- Vagante, action RPG platform game.
- The Shooting of Isaac, vertical shooter game.
- Open Hexagon, free open-source Super Hexagon clone.
- Pirates Treasure
- Enchanted Forest
- Limit Theory, infinite, procedural space game.
- Postmortem: one must die, narrative adventure game.
- Pioneers, turn based exploration game with some RPG elements.
- Zloxx, 2D action platformer.
- KeeperRL, dungeon simulator with rogue-like and RPG elements.
- Hope, point and click adventure game (like Myst).
Other software use
- Aquila, open source digital signal processing (DSP) library for C++.
- Otter, a 2D C# framework built on SFML 2.
- GDevelop, open source game creation software.
- Immersion Engine, tool to visualize detailed landscapes and architecture.
- Cross-platform support middleware
- OpenGL Utility Toolkit (GLUT)
- Simple DirectMedia Layer (SDL)
- "Bindings (SFML / Download)". SFML. Retrieved 13 November 2014.
- "Changelog (SFML / Development)". Retrieved 18 December 2014.
- Gomila, Laurent. "SFML 2.1 (SFML / Download)". SFML. Retrieved 9 August 2014.
- "SFML/Config.cmake at f24ca9a84012531cf886f72354c1f88341dd7ac7 · SFML/SFML". GitHub. Retrieved 13 November 2014.
- "SFGUI". SFGUI. Retrieved 13 November 2014.
- "TGUI". TGUI. Retrieved 13 November 2014.
- "hovatterz/light". GitHub. Retrieved 13 November 2014.
- "Bromeon :: Thor". Jan Haller. Retrieved 13 November 2014.
- "sfeMovie". sfeMovie. Retrieved 13 November 2014.
- "Tiled SFML Map Loader | SourceForge.net". SourceForge. Retrieved 13 November 2014.
- "sfml | Ludum Dare". Ludum Dare. Retrieved 13 November 2014.
- "SFML/SFML". GitHub. 26 August 2015. Retrieved 26 August 2015.
- "SFML Setup". University of Mary Washington. Retrieved 13 November 2014.
- "Rensselaer Center for Open Source Software". Rensselaer Polytechnic Institute. Retrieved 13 November 2014.
- "CSCI 261 - Programming Concepts". Colorado School of Mines. Retrieved 13 November 2014.
- "COMPSCI 464: Computer Graphics". Boise State University. Retrieved 13 November 2014.
- "Engaging Computing Group | Comp4spr14 / PS5b". University of Massachusetts Lowell. Retrieved 13 November 2014.
- "Tianyu Cheng's Homepage". University of Texas at Austin. Retrieved 13 November 2014.
- Chung, Brendon (20 August 2011). "Atom Zombie Tech « Blendo news". Blendo Games. Retrieved 9 August 2014.
- "Chesster [SFML Puzzle Game]". 18 October 2011. Retrieved 13 November 2014.
- "cosmoscroll - SFML-based shoot'em up game. - Google Project Hosting". Google Project Hosting. Retrieved 19 July 2015.
- "Development Update - Lighting and Saving | Siege Games". Siege Games. 3 April 2012. Retrieved 13 November 2014.
- "HolySpirit Windows game | Desura". Desura. 13 November 2014. Retrieved 19 July 2015.
- "Kroniax available in the Play Store!". Retrieved 15 November 2014.
- "M.A.R.S. - a ridiculous shooter - M.A.R.S. 0.7.2 Bugfix Release". M.A.R.S. 26 April 2011. Retrieved 13 November 2014.
- "SFML 2.0 | BP | I make video games.". Ben Porter. Retrieved 13 November 2014.
- "LZR Ovid the Owl". Leeran Z. Raphaely. Retrieved 13 November 2014.
- "Version 1.0.2 is available of PC and Linux news - Project Black Sun Game - Indie DB". Indie DB. 20 December 2011. Retrieved 13 November 2014.
- "The Duke". 8 June 2009. Retrieved 13 November 2014.
- "Vagante | Tools of the Trade". Vagante Game. 3 December 2013. Retrieved 13 November 2014.
- "Philippe Offermann » The Shooting Of Isaac". Philippe Offerman. Retrieved 13 November 2014.
- "Open Hexagon - challenging fast paced game". Retrieved 13 November 2014.
- "Pirate's Treasure & Enchanted Forest". Retrieved 13 November 2014.
- "Limit Theory Forums • View topic - SFML::Texturing". Retrieved 13 November 2014.
- "Tools and resources for making an indie game | Koobazaur's Domain". Jakub Kasztalski. Retrieved 13 November 2014.
- "Eigen's development notes". Eigen Lenk. Retrieved 13 November 2014.
- "Zloxx II - An action Jump'n'Run". Retrieved 15 November 2014.
- "miki151/keeperrl". Retrieved 11 January 2015.
- "FAQ - Hope Dev Blog". Retrieved 11 August 2015.
- "Download | Aquila - a C++ library for digital signal processing". Zbigniew Siciarz. Retrieved 13 November 2014.
- "Otter - A 2D C# Framework built on SFML 2". Kyle Pulver. Retrieved 13 November 2014.
- "Florian Rival's personal website". Florian Rival. Retrieved 14 November 2014.
- "Good news for ImmersionEngine". Facebook. Retrieved 12 February 2015.
- Jan Haller, Henrik Vogelius Hansson, Artur Moreira: SFML Game Development, Packt Publishing, ISBN 1-849696-84-5