void SoundSystemOAL::pause() { log::messageln("SoundSystemOAL::pause"); /* for (channels::iterator i = _channels.begin(); i != _channels.end(); ++i) { ChannelOAL& channel = *i; channel.pause(); } */ #if defined(__ANDROID__) //android needs special workaround alcSuspend(); #endif #if defined(__S3E__) alcSuspendContext(_context); alcMakeContextCurrent(0); #endif }
void Sound::Suspend() { //Always check if openal is initialized if (!OpenALInit()) return; OpenALChannel* channel = 0; for (int i = 0; i < sgOpenChannels.size(); i++) { channel = (OpenALChannel*)(sgOpenChannels[i]); if (channel) { channel->suspend(); } } alcMakeContextCurrent(0); alcSuspendContext(sgContext); #ifdef ANDROID alcSuspend(); #endif }