SDL_sound
April 20th, 2008: stable branch SDL_sound 1.0.3 released!
September 9th, 2008: We have switched from Subversion to Mercurial.
SDL_sound is a library that handles the decoding of several popular
sound file formats, such as .WAV and .MP3. It is meant to make the
programmer's sound playback tasks simpler. The programmer gives
SDL_sound a filename, or feeds it data directly from one of many
sources, and then reads the decoded waveform data back at her leisure.
If resource constraints are a concern, SDL_sound can process sound
data in programmer-specified blocks. Alternately, SDL_sound can decode
a whole sound file and hand back a single pointer to the whole waveform.
SDL_sound can also handle sample rate, audio format, and channel
conversion on-the-fly and behind-the-scenes, if the programmer desires.
As the name implies, SDL_sound is an add-on to
Simple Directmedia Layer, and
as such, you'll need it to build and use SDL_sound. SDL gives us lots of
convenience for porting and implementing some elements of the library,
not to mention that it is a powerful, cross platform answer to
DirectX. You should definitely look
into it, whether you use SDL_sound or not.
Places SDL_sound is known to be used:
- Procedural Arts' innovative interactive drama,
Façade, uses
SDL_sound to decode audio in the Mac OS X version.
- PopCap uses SDL_sound for the Mac OS X versions of
Feeding Frenzy,
Pizza Frenzy, and
Iggle Pop!
(and maybe others).
- The Ambient
Music System uses SDL_sound in its
player module.
- The popular game glTron uses
SDL_sound for sound playback.
- Dominik Haumann wrote in to mention C++ wrappers for SDL_sound,
which can be found
here.
-
MusicBox, a GNUstep music manager, uses SDL_sound to
decode various audio formats.
- The SuSE Linux distribution has
been known to package SDL_sound.
- Gentoo Linux distributes
SDL_sound via their "portage" system. Just "emerge sdl-sound".
- FreeBSD has SDL_sound in
their Ports tree: here're the
details.
- NetBSD appears to have
packaged SDL_sound:
details.
- Debian has packaged
SDL_sound, too:
details.
- ROCK Linux has an
SDL_sound package:
details.
- Arch Linux publishes an
official SDL_sound package.
Details.
- Ubuntu Linux has an
SDL_sound package:
details.
- Probably other places. Email me if you want to be listed here.
What works:
- Support for "decoding" raw audio samples.
- Support for decoding Microsoft WAVE audio files (uncompressed
and MS-ADPCM encoded waveforms are supported, currently) (.WAV).
- Support for decoding various MPEG audio files through
SMPEG
(.MP3, .MPG, .MPEG).
- Support for decoding MPEG-1 Layer 3 audio files internally
(makes use of LGPL'd code from mpg123.)
(.MP3).
- Support for decoding MIDI music files (.MIDI, .MID).
- Support for decoding Ogg Vorbis audio files through
libvorbis
(.OGG).
- Support for decoding Speex voice files through
libspeex
(.SPX).
- Support for decoding FLAC audio files through
libFLAC
(.FLAC, .FLA).
- Support for decoding Creative Labs Voice files (.VOC).
- Support for decoding Audio Interchange File Format files (.AIFF).
- Support for decoding Shorten-compressed audio data (.SHN).
- Support for Sun's audio format (.AU).
- Support for decoding through
MikMod.
(.MOD, .IT, .XM, .S3M, .MTM, .669, .STM, .ULT, .FAR, .MED, .AMF,
.DSM, .IMF, .GDM, .STX, .OKT).
- Support for decoding through
ModPlug.
(.669, .AMF, .AMS, .DBM, .DMF, .DSM, .FAR, .IT, .MDL, .MED, .MOD,
.MT2, .MTM, .OKT, .PTM, .PSM, .S3M, .STM, .ULT, .UMX, .XM)
- Experimental support for decoding through
Apple Quicktime
(MacOS only).
- Compiles/runs on Linux (x86 tested).
- Compiles/runs on Linux (x86-64 tested).
- Compiles/runs on Linux (PowerPC tested).
- Compiles/runs on FreeBSD (x86 tested).
- Compiles/runs on Win32 (x86 tested).
- Compiles/runs on MacOS Classic (PowerPC tested).
- Compiles/runs on MacOS X (PowerPC tested).
- Compiles/runs on BeOS (x86 tested).
- Compiles/runs on WinCE/PocketPC (StrongARM tested).
- May compile and run elsewhere with little to no modification.
Success stories and patches are
welcome.
What doesn't work:
- Support for more forms of compressed .WAV files is planned,
but not yet implemented.
- Support for various forms of compressed .AIFF files is planned,
but not yet implemented.
- Contributions of other ports are, of course,
welcome.
License:
SDL_sound is licensed under the
GNU Lesser General Public License version 2.1 (or newer, at your option).
Those interested in a closed-source license may
contact me
about licensing fees.
Documentation:
A Doxygen-generated API reference
can be found here. You can generate your own
HTML, manpage, LaTeX, RTF, etc documents with this program; download
the SDL_sound source and use the included Doxyfile.
Downloads:
Prepackaged source code and binaries:
- Here is the CHANGELOG.
- Here are the latest officially released
binaries and source. Please be aware that we do not make a
habit of building binaries for any platform, and when we
do, we don't support them. Use the source, or find a distro you
trust to prepackage them for you (see several at the top of this
page).
-
This page has SDL_sound RPMs for LSB-compliant distros such
as SuSE. Regular, developer, and source RPMs available.
- SourceMage maintains an
SDL_sound package.
- If you are interested in maintaining packages for various
platforms (MacOS X, Windows, etc), please
drop me a line.
Downloading with Mercurial:
SDL_sound's source code may be downloaded using
Mercurial (aka: "hg"). Hg
allows you to get up-to-the-minute fixes and enhancements; as a developer
works on a source tree, you can use hg to mirror that source tree
instead of waiting for an official release. Please look at the
Mercurial website
for more information on using hg, where you can also download
software for Mac OS X, Windows, and Unix systems.
SDL_sound is no longer hosted in a CVS or Subversion repository. You
have to use hg or wait for an official release.
Here is the web interface to SDL_sound's Mercurial repository.
To download SDL_sound via Mercurial:
hg clone hg.icculus.org/icculus/SDL_sound/
...or, for the stable (non-development) branch:
hg clone -r stable-1.0 hg.icculus.org/icculus/SDL_sound/
Mailing list:
There is a mailing list for SDL_sound available. To subscribe,
head to the mailman page.
Then, to send mail to the list, write to
sdlsound@icculus.org.
Page maintained by
Ryan C. Gordon.
gipoco.com
is neither affiliated with the authors of this page or responsible
for its contents. This is a safe-cache copy of the original web site.
gipoco.com
is neither affiliated with the authors of this page nor responsible
for its contents. This is a safe-cache copy of the original web site.