add alcSuspendContext and alcProcessContext again to prevent sound artifacts on hardware accelerated soundcards.

This commit is contained in:
ehofman
2009-12-06 09:56:01 +00:00
committed by Tim Moore
parent 47617d6c04
commit b1200f9f59

View File

@@ -274,6 +274,8 @@ void SGSoundMgr::unbind ()
// run the audio scheduler
void SGSoundMgr::update( double dt ) {
if (_active) {
alcSuspendContext(_context);
if (_changed) {
update_pos_and_orientation();
}
@@ -310,6 +312,8 @@ if (isNaN(_velocity.data())) printf("NaN in listener velocity\n");
testForALError("update");
_changed = false;
}
alcProcessContext(_context);
}
}