Blender V2.61 - r43446
|
#include <AUD_IDevice.h>
Public Member Functions | |
virtual | ~AUD_IDevice () |
virtual AUD_DeviceSpecs | getSpecs () const =0 |
virtual AUD_Reference < AUD_IHandle > | play (AUD_Reference< AUD_IReader > reader, bool keep=false)=0 |
virtual AUD_Reference < AUD_IHandle > | play (AUD_Reference< AUD_IFactory > factory, bool keep=false)=0 |
virtual void | stopAll ()=0 |
virtual void | lock ()=0 |
virtual void | unlock ()=0 |
virtual float | getVolume () const =0 |
virtual void | setVolume (float volume)=0 |
This class represents an output device for sound sources. Output devices may be several backends such as plattform independand like SDL or OpenAL or plattform specific like DirectSound, but they may also be files, RAM buffers or other types of streams.
Definition at line 47 of file AUD_IDevice.h.
virtual AUD_IDevice::~AUD_IDevice | ( | ) | [inline, virtual] |
Destroys the device.
Definition at line 53 of file AUD_IDevice.h.
virtual AUD_DeviceSpecs AUD_IDevice::getSpecs | ( | ) | const [pure virtual] |
Returns the specification of the device.
Implemented in AUD_NULLDevice, AUD_SoftwareDevice, and AUD_OpenALDevice.
virtual float AUD_IDevice::getVolume | ( | ) | const [pure virtual] |
Retrieves the overall device volume.
Implemented in AUD_NULLDevice, AUD_SoftwareDevice, and AUD_OpenALDevice.
virtual void AUD_IDevice::lock | ( | ) | [pure virtual] |
Locks the device. Used to make sure that between lock and unlock, no buffers are read, so that it is possible to start, resume, pause, stop or seek several playback handles simultaneously.
Implemented in AUD_NULLDevice, AUD_SoftwareDevice, and AUD_OpenALDevice.
virtual AUD_Reference<AUD_IHandle> AUD_IDevice::play | ( | AUD_Reference< AUD_IReader > | reader, |
bool | keep = false |
||
) | [pure virtual] |
Plays a sound source.
reader | The reader to play. |
keep | When keep is true the sound source will not be deleted but set to paused when its end has been reached. |
AUD_Exception | Thrown if there's an unexpected (from the device side) error during creation of the reader. |
Implemented in AUD_NULLDevice, AUD_SoftwareDevice, and AUD_OpenALDevice.
virtual AUD_Reference<AUD_IHandle> AUD_IDevice::play | ( | AUD_Reference< AUD_IFactory > | factory, |
bool | keep = false |
||
) | [pure virtual] |
Plays a sound source.
factory | The factory to create the reader for the sound source. |
keep | When keep is true the sound source will not be deleted but set to paused when its end has been reached. |
AUD_Exception | Thrown if there's an unexpected (from the device side) error during creation of the reader. |
Implemented in AUD_NULLDevice, AUD_SoftwareDevice, and AUD_OpenALDevice.
virtual void AUD_IDevice::setVolume | ( | float | volume | ) | [pure virtual] |
Sets the overall device volume.
handle | The sound handle. |
volume | The overall device volume. |
Implemented in AUD_NULLDevice, AUD_SoftwareDevice, and AUD_OpenALDevice.
virtual void AUD_IDevice::stopAll | ( | ) | [pure virtual] |
Stops all playing sounds.
Implemented in AUD_NULLDevice, AUD_SoftwareDevice, and AUD_OpenALDevice.
virtual void AUD_IDevice::unlock | ( | ) | [pure virtual] |
Unlocks the previously locked device.
Implemented in AUD_NULLDevice, AUD_SoftwareDevice, and AUD_OpenALDevice.