Tech moves fast! Stay ahead of the curve with Techopedia!
Join nearly 200,000 subscribers who receive actionable tech insights from Techopedia.
Simple directmedia layer (SDL) is a cross-platform multimedia library written in C to provide low level access to keyboard, mouse, audio, joystick and 3D hardware through OpenGL. It is also used by MPEG playback software and many popular games.
It also provides bindings to many other languages, including (a partial listing):
Thus, it is a common choice for many multimedia applications. It is also distributed under GNU LGPL version 2 and enables game development for several platforms at the same time, and porting of the game to a new platform within time. While the SDL sound features are modest, the SDL API, which is mainly graphic related, holds around 200 functions and a few structures. It also offers tools for parallel programming such as semaphores, mutex, condition variables and threads.
SDL has the title layer as its wrapper around specific operating system's functionality providing access to it. The SDL source codes are split into different modules for specific operating systems. On compilation, the right modules are selected for the target system. SDL use a GDI backend for Microsoft Windows, while it makes use of the Xlib to communicate with the Linux and OpenVMS for graphics and events.