Magnum::Audio namespace

Audio playback.

Audio import, playback and integration with SceneGraph.

This library depends on the OpenAL library. It is built if WITH_AUDIO is enabled when building Magnum. To use this library with CMake, you need to request the Audio component of the Magnum package and link to the Magnum::Audio target:

find_package(Magnum REQUIRED Audio)

# ...
target_link_libraries(your-app Magnum::Audio)

See Downloading and building and Usage with CMake for more information.

Additional plugins are built separately, see particular Audio::*Importer class documentation, Downloading and building, Downloading and building plugins, Usage with CMake, Plugin usage with CMake and Loading and using plugins for more information.

Namespaces

namespace Extensions
Compile-time information about OpenAL extensions.

Classes

class AbstractImporter
Base for audio importer plugins.
class AnyImporter
Any audio importer plugin.
class Buffer
Sample buffer.
class Context
OpenAL context.
class DrFlacImporter
FLAC audio importer plugin using dr_flac.
class DrWavImporter
WAV audio importer plugin using dr_wav.
class Extension
Run-time information about OpenAL extension.
template<UnsignedInt dimensions>
class Listener
Listener.
template<UnsignedInt dimensions>
class Playable
Playable.
template<UnsignedInt dimensions>
class PlayableGroup
PlayableGroup.
class Renderer
Global renderer configuration.
class Source
Source.
class StbVorbisImporter
OGG audio importer plugin using stb_vorbis.
class WavImporter
WAV importer plugin.

Enums

enum class BufferFormat: ALenum { Mono8 = AL_FORMAT_MONO8, Mono16 = AL_FORMAT_MONO16, Stereo8 = AL_FORMAT_STEREO8, Stereo16 = AL_FORMAT_STEREO16, MonoALaw = AL_FORMAT_MONO_ALAW_EXT, StereoALaw = AL_FORMAT_STEREO_ALAW_EXT, MonoMuLaw = AL_FORMAT_MONO_MULAW_EXT, StereoMuLaw = AL_FORMAT_STEREO_MULAW_EXT, MonoFloat = AL_FORMAT_MONO_FLOAT32, StereoFloat = AL_FORMAT_STEREO_FLOAT32, MonoDouble = AL_FORMAT_MONO_DOUBLE_EXT, StereoDouble = AL_FORMAT_STEREO_DOUBLE_EXT, Quad8 = AL_FORMAT_QUAD8, Quad16 = AL_FORMAT_QUAD16, Quad32 = AL_FORMAT_QUAD32, Rear8 = AL_FORMAT_REAR8, Rear16 = AL_FORMAT_REAR16, Rear32 = AL_FORMAT_REAR32, Surround51Channel8 = AL_FORMAT_51CHN8, Surround51Channel16 = AL_FORMAT_51CHN16, Surround51Channel32 = AL_FORMAT_51CHN32, Surround61Channel8 = AL_FORMAT_61CHN8, Surround61Channel16 = AL_FORMAT_61CHN16, Surround61Channel32 = AL_FORMAT_61CHN32, Surround71Channel8 = AL_FORMAT_71CHN8, Surround71Channel16 = AL_FORMAT_71CHN16, Surround71Channel32 = AL_FORMAT_71CHN32 }
Buffer sample format.

Typedefs

using Listener2D = Listener<2>
Listener for two-dimensional float scenes.
using Listener3D = Listener<3>
Listener for three-dimensional float scenes.
using Playable2D = Playable<2>
Playable for two-dimensional float scenes.
using Playable3D = Playable<3>
Playable for three-dimensional float scenes.
using PlayableGroup2D = PlayableGroup<2>
Playable group for two dimensional float scenes.
using PlayableGroup3D = PlayableGroup<3>
Playable group for three dimensional float scenes.

Functions

auto operator<<(Debug& debug, BufferFormat value) -> Debug&
Debug output operator.
auto operator<<(Debug& debug, Context::HrtfStatus value) -> Debug&
Debug output operator.
auto operator<<(Debug& debug, Renderer::Error value) -> Debug&
Debug output operator.
auto operator<<(Debug& debug, Renderer::DistanceModel value) -> Debug&
Debug output operator.
auto operator<<(Debug& debug, Source::State value) -> Debug&
Debug output operator.

Enum documentation

enum class Magnum::Audio::BufferFormat: ALenum

Buffer sample format.

Enumerators
Mono8

8-bit unsigned mono

Mono16

16-bit signed mono

Stereo8

8-bit interleaved unsigned stereo

Stereo16

16-bit interleaved signed stereo

MonoALaw

8-bit mono A-Law Compressed Sound Format

StereoALaw

8-bit interleaved stereo A-Law Compressed Sound Format

MonoMuLaw

8-bit mono μ-Law Compressed Sound Format

StereoMuLaw

8-bit interleaved μ-Law Compressed Sound Format

MonoFloat

32-bit floating-point mono

StereoFloat

32-bit interleaved floating-point stereo

MonoDouble

64-bit floating-point mono

StereoDouble

64-bit interleaved floating-point stereo

Quad8

8-bit unsigned quadrophonic

Quad16

16-bit signed quadrophonic

Quad32

32-bit interleaved floating-point quadrophonic

Rear8

8-bit unsigned rear

Rear16

16-bit signed rear

Rear32

32-bit interleaved floating-point rear

Surround51Channel8

8-bit unsigned 5.1 surround

Surround51Channel16

16-bit signed 5.1 surround

Surround51Channel32

32-bit interleaved floating-point 5.1 surround

Surround61Channel8

8-bit unsigned 6.1 surround

Surround61Channel16

16-bit signed 6.1 surround

Surround61Channel32

32-bit interleaved floating-point 6.1 surround

Surround71Channel8

8-bit unsigned 7.1 surround

Surround71Channel16

16-bit signed 7.1 surround

Surround71Channel32

32-bit interleaved floating-point 7.1 surround

Typedef documentation

typedef Listener<2> Magnum::Audio::Listener2D

Listener for two-dimensional float scenes.

typedef Listener<3> Magnum::Audio::Listener3D

Listener for three-dimensional float scenes.

typedef Playable<2> Magnum::Audio::Playable2D

Playable for two-dimensional float scenes.

typedef Playable<3> Magnum::Audio::Playable3D

Playable for three-dimensional float scenes.

typedef PlayableGroup<2> Magnum::Audio::PlayableGroup2D

Playable group for two dimensional float scenes.

typedef PlayableGroup<3> Magnum::Audio::PlayableGroup3D

Playable group for three dimensional float scenes.

Function documentation

Debug& Magnum::Audio::operator<<(Debug& debug, BufferFormat value)

Debug output operator.

Debug& Magnum::Audio::operator<<(Debug& debug, Context::HrtfStatus value)

Debug output operator.

Debug& Magnum::Audio::operator<<(Debug& debug, Renderer::Error value)

Debug output operator.

Debug& Magnum::Audio::operator<<(Debug& debug, Renderer::DistanceModel value)

Debug output operator.

Debug& Magnum::Audio::operator<<(Debug& debug, Source::State value)

Debug output operator.