Vegastrike 0.5.1 rc1
1.0
Original sources for Vegastrike Evolved
|
#include <OpenALSimpleSound.h>
Public Member Functions | |
OpenALSimpleSound (const std::string &name, VSFileSystem::VSFileType type=VSFileSystem::UnknownFile) throw () | |
ALBufferHandle | getAlBuffer () const |
virtual | ~OpenALSimpleSound () |
![]() | |
virtual | ~SimpleSound () |
VSFileSystem::VSFileType | getType () const |
![]() | |
virtual | ~Sound () |
const std::string & | getName () const throw () |
const Format & | getFormat () const throw () |
bool | isLoaded () const throw () |
bool | isLoading () const throw () |
bool | isStreaming () const throw () |
void | load (bool wait=true) throw (Exception) |
void | unload () throw () |
Protected Member Functions | |
virtual void | loadImpl (bool wait) throw (Exception) |
virtual void | unloadImpl () throw () |
![]() | |
SimpleSound (const std::string &name, VSFileSystem::VSFileType type=VSFileSystem::UnknownFile, bool streaming=false) throw () | |
bool | isStreamLoaded () const |
void | loadStream () throw (Exception) |
void | closeStream () throw (ResourceNotLoadedException) |
SharedPtr< Stream > | getStream () const throw (ResourceNotLoadedException) |
void | readBuffer (SoundBuffer &buffer) throw (Exception) |
virtual void | abortLoad () throw () |
![]() | |
Sound (const std::string &name, bool streaming) throw () | |
Format & | getFormat () throw () |
virtual void | onLoaded (bool success) throw () |
virtual void | waitLoad () throw (Exception) |
Additional Inherited Members | |
![]() | |
struct Audio::Sound::Flags | flags |
OpenAL Simple Sound implementation class
Definition at line 25 of file OpenALSimpleSound.h.
Audio::OpenALSimpleSound::OpenALSimpleSound | ( | const std::string & | name, |
VSFileSystem::VSFileType | type = VSFileSystem::UnknownFile |
||
) | |||
throw | ( | ||
) |
Internal constructor used by derived classes
Definition at line 25 of file OpenALSimpleSound.cpp.
|
virtual |
Definition at line 32 of file OpenALSimpleSound.cpp.
|
inline |
Package-private: the OpenAL renderer package uses this, YOU DON'T
Definition at line 34 of file OpenALSimpleSound.h.
Load the resource
Implements Audio::Sound.
Definition at line 36 of file OpenALSimpleSound.cpp.
References Audio::__impl::OpenAL::asALFormat(), Audio::Format::bitsPerSample, buffer, checkAlError, clearAlError, e, Audio::SoundBuffer::getBuffer(), Audio::SoundBuffer::getUsedBytes(), max(), VsnetOSS::memcpy(), Audio::Format::nativeOrder, Audio::SoundBuffer::optimize(), Audio::SoundBuffer::reserve(), Audio::Format::sampleFrequency, Audio::SoundBuffer::setUsedBytes(), Audio::Format::signedSamples, and Audio::SoundBuffer::swap().
|
protectedvirtual |
Unload the resource.
Implements Audio::Sound.
Definition at line 153 of file OpenALSimpleSound.cpp.
References AL_NULL_BUFFER.