OpenMW
Classes | Private Types | Private Member Functions | Private Attributes | Friends
MWSound::OpenAL_Output Class Reference

#include <openal_output.hpp>

List of all members.

Classes

struct  StreamThread

Private Types

typedef std::deque< ALuint > IDDq
typedef std::map< std::string,
ALuint > 
NameMap
typedef std::map< ALuint, ALuint > IDRefMap
typedef std::vector< Sound * > SoundVec

Private Member Functions

ALuint getBuffer (const std::string &fname)
void bufferFinished (ALuint buffer)
virtual std::vector< std::string > enumerate ()
virtual void init (const std::string &devname="")
virtual void deinit ()
virtual MWBase::SoundPtr playSound (const std::string &fname, float vol, float basevol, float pitch, int flags, float offset)
virtual MWBase::SoundPtr playSound3D (const std::string &fname, const Ogre::Vector3 &pos, float vol, float basevol, float pitch, float min, float max, int flags, float offset)
virtual MWBase::SoundPtr streamSound (DecoderPtr decoder, float volume, float pitch, int flags)
virtual void updateListener (const Ogre::Vector3 &pos, const Ogre::Vector3 &atdir, const Ogre::Vector3 &updir, Environment env)
virtual void pauseSounds (int types)
virtual void resumeSounds (int types)
OpenAL_Outputoperator= (const OpenAL_Output &rhs)
 OpenAL_Output (const OpenAL_Output &rhs)
 OpenAL_Output (SoundManager &mgr)
virtual ~OpenAL_Output ()

Private Attributes

ALCdevice * mDevice
ALCcontext * mContext
IDDq mFreeSources
IDDq mUnusedBuffers
NameMap mBufferCache
IDRefMap mBufferRefs
uint64_t mBufferCacheMemSize
SoundVec mActiveSounds
Environment mLastEnvironment
std::auto_ptr< StreamThreadmStreamThread

Friends

class OpenAL_Sound
class OpenAL_Sound3D
class OpenAL_SoundStream
class SoundManager

Member Typedef Documentation

typedef std::deque<ALuint> MWSound::OpenAL_Output::IDDq [private]
typedef std::map<ALuint,ALuint> MWSound::OpenAL_Output::IDRefMap [private]
typedef std::map<std::string,ALuint> MWSound::OpenAL_Output::NameMap [private]
typedef std::vector<Sound*> MWSound::OpenAL_Output::SoundVec [private]

Constructor & Destructor Documentation


Member Function Documentation

void MWSound::OpenAL_Output::bufferFinished ( ALuint  buffer) [private]
void MWSound::OpenAL_Output::deinit ( ) [private, virtual]

Implements MWSound::Sound_Output.

std::vector< std::string > MWSound::OpenAL_Output::enumerate ( ) [private, virtual]

Implements MWSound::Sound_Output.

ALuint MWSound::OpenAL_Output::getBuffer ( const std::string &  fname) [private]
void MWSound::OpenAL_Output::init ( const std::string &  devname = "") [private, virtual]

Implements MWSound::Sound_Output.

OpenAL_Output& MWSound::OpenAL_Output::operator= ( const OpenAL_Output rhs) [private]
void MWSound::OpenAL_Output::pauseSounds ( int  types) [private, virtual]

Implements MWSound::Sound_Output.

MWBase::SoundPtr MWSound::OpenAL_Output::playSound ( const std::string &  fname,
float  vol,
float  basevol,
float  pitch,
int  flags,
float  offset 
) [private, virtual]
Parameters:
offsetValue from [0,1] meaning from which fraction the sound the playback starts.

Implements MWSound::Sound_Output.

MWBase::SoundPtr MWSound::OpenAL_Output::playSound3D ( const std::string &  fname,
const Ogre::Vector3 &  pos,
float  vol,
float  basevol,
float  pitch,
float  min,
float  max,
int  flags,
float  offset 
) [private, virtual]
Parameters:
offsetValue from [0,1] meaning from which fraction the sound the playback starts.

Implements MWSound::Sound_Output.

void MWSound::OpenAL_Output::resumeSounds ( int  types) [private, virtual]

Implements MWSound::Sound_Output.

MWBase::SoundPtr MWSound::OpenAL_Output::streamSound ( DecoderPtr  decoder,
float  volume,
float  pitch,
int  flags 
) [private, virtual]

Implements MWSound::Sound_Output.

void MWSound::OpenAL_Output::updateListener ( const Ogre::Vector3 &  pos,
const Ogre::Vector3 &  atdir,
const Ogre::Vector3 &  updir,
Environment  env 
) [private, virtual]

Implements MWSound::Sound_Output.


Friends And Related Function Documentation

friend class OpenAL_Sound [friend]
friend class OpenAL_Sound3D [friend]
friend class OpenAL_SoundStream [friend]
friend class SoundManager [friend]

Reimplemented from MWSound::Sound_Output.


Member Data Documentation

ALCcontext* MWSound::OpenAL_Output::mContext [private]
ALCdevice* MWSound::OpenAL_Output::mDevice [private]

The documentation for this class was generated from the following files: