55 for (std::vector<SoundEmitter*>::iterator it =
m_emittervec.begin(), it_end =
m_emittervec.end(); it != it_end; ++it) {
69 if (alcGetError(NULL) != ALC_NO_ERROR) {
78 FL_ERR(
_log,
LMsg() <<
"Could not open audio device - deactivating audio module");
85 FL_ERR(
_log,
LMsg() <<
"Couldn't create audio context - deactivating audio module");
91 if (alcGetError(
m_device) != ALC_NO_ERROR) {
92 FL_ERR(
_log,
LMsg() <<
"Couldn't change current audio context - deactivating audio module");
98 alListener3f(AL_POSITION, 0.0, 0.0, 0.0);
99 ALfloat vec1[6] = { 0.0, 0.0, 0.0, 0.0, 0.0, 1.0};
100 alListenerfv(AL_ORIENTATION, vec1);
Helper class to create log strings out from separate parts Usage: LMsg("some text") << variable << "...
SoundEmitter * createEmitter()
Returns a pointer to an allocated emitter-instance.
static Logger _log(LM_AUDIO)
#define FL_ERR(logger, msg)
void init()
Initializes the audio system.
The class for playing audio files.
std::vector< SoundEmitter * > m_emittervec
void releaseEmitter(uint32_t emitterid)
Release an emitter-instance given by emitter-id.
SoundEmitter * getEmitter(uint32_t emitterid) const
Returns a pointer to an emitter-instance given by emitterid.