PixelLightAPI
.
|
Abstract sound buffer resource. More...
#include <Buffer.h>
Public Member Functions | |
virtual PLSOUND_API | ~Buffer () |
Destructor. | |
PLSOUND_API PLCore::uint32 | GetNumOfSources () const |
Returns the number of sources. | |
PLSOUND_API const Source * | GetSource (PLCore::uint32 nIndex=0) const |
Returns a sound source. | |
PLSOUND_API Source * | GetSource (PLCore::uint32 nIndex=0) |
Returns a sound source. | |
virtual bool | LoadBuffer (const PLCore::String &sFilename, bool bStream)=0 |
Loads the sound buffer with the given data from a file. | |
virtual bool | LoadBuffer (const PLCore::uint8 nData[], PLCore::uint32 nSize, bool bStream=false)=0 |
Loads the sound buffer with the given data from memory. | |
virtual bool | IsLoaded () const =0 |
Returns whether the buffer is loaded or not. | |
virtual bool | IsStreamed () const =0 |
Returns whether the buffer is streamed or not. | |
Protected Member Functions | |
PLSOUND_API | Buffer (SoundManager &cSoundManager, const PLCore::String &sName="") |
Constructor. |
Abstract sound buffer resource.
virtual PLSOUND_API PLSound::Buffer::~Buffer | ( | ) | [virtual] |
Destructor.
PLSOUND_API PLSound::Buffer::Buffer | ( | SoundManager & | cSoundManager, |
const PLCore::String & | sName = "" |
||
) | [protected] |
Constructor.
[in] | cSoundManager | Owner sound manager |
[in] | sName | Resource name to set |
PLSOUND_API PLCore::uint32 PLSound::Buffer::GetNumOfSources | ( | ) | const |
Returns the number of sources.
PLSOUND_API const Source* PLSound::Buffer::GetSource | ( | PLCore::uint32 | nIndex = 0 | ) | const |
Returns a sound source.
[in] | nIndex | Index of the resource to return |
PLSOUND_API Source* PLSound::Buffer::GetSource | ( | PLCore::uint32 | nIndex = 0 | ) |
Returns a sound source.
[in] | nIndex | Index of the resource to return |
virtual bool PLSound::Buffer::LoadBuffer | ( | const PLCore::String & | sFilename, |
bool | bStream | ||
) | [pure virtual] |
Loads the sound buffer with the given data from a file.
[in] | sFilename | Sound filename (full path, supported file formats are API dependent) |
[in] | bStream | Stream the file? |
virtual bool PLSound::Buffer::LoadBuffer | ( | const PLCore::uint8 | nData[], |
PLCore::uint32 | nSize, | ||
bool | bStream = false |
||
) | [pure virtual] |
Loads the sound buffer with the given data from memory.
[in] | nData | Sound data |
[in] | nSize | Number of data bytes (MUST be valid!) |
[in] | bStream | Stream the data? |
virtual bool PLSound::Buffer::IsLoaded | ( | ) | const [pure virtual] |
Returns whether the buffer is loaded or not.
virtual bool PLSound::Buffer::IsStreamed | ( | ) | const [pure virtual] |
Returns whether the buffer is streamed or not.
|