diff options
author | Andrey Lihatskiy <alihatskiy@productengine.com> | 2024-06-10 20:03:54 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-06-10 20:03:54 +0300 |
commit | f74c10c4ec6435471bac84473fe865f90843c2df (patch) | |
tree | b2853d87789dbb84d6c26c259eab6639d3a7e482 /indra/llaudio/llaudioengine_openal.cpp | |
parent | 5fccb539937a52d286274a002266e022e2102e5e (diff) | |
parent | 32fcefc058ae38eff0572326ef3efd1c7b343144 (diff) |
Merge branch 'DRTVWR-600-maint-A' into signal/trim-trailing
Diffstat (limited to 'indra/llaudio/llaudioengine_openal.cpp')
-rw-r--r-- | indra/llaudio/llaudioengine_openal.cpp | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/indra/llaudio/llaudioengine_openal.cpp b/indra/llaudio/llaudioengine_openal.cpp index 1c4c67e6f6..18d682b554 100644 --- a/indra/llaudio/llaudioengine_openal.cpp +++ b/indra/llaudio/llaudioengine_openal.cpp @@ -135,10 +135,19 @@ void LLAudioEngine_OpenAL::shutdown() LL_INFOS() << "About to LLAudioEngine::shutdown()" << LL_ENDL; LLAudioEngine::shutdown(); + // If a subsequent error occurs while there is still an error recorded + // internally, the second error will simply be ignored. + // Clear previous error to make sure we will captuare a valid failure reason + ALenum error = alutGetError(); + if (error != ALUT_ERROR_NO_ERROR) + { + LL_WARNS() << "Uncleared error state prior to shutdown: " + << alutGetErrorString(error) << LL_ENDL; + } + LL_INFOS() << "About to alutExit()" << LL_ENDL; if(!alutExit()) { - LL_WARNS() << "Nuts." << LL_ENDL; LL_WARNS() << "LLAudioEngine_OpenAL::shutdown() ALUT shutdown failed: " << alutGetErrorString (alutGetError ()) << LL_ENDL; } @@ -518,7 +527,7 @@ void LLAudioEngine_OpenAL::updateWind(LLVector3 wind_vec, F32 camera_altitude) } alBufferData(buffer, - AL_FORMAT_STEREO16, + AL_FORMAT_STEREO_FLOAT32, mWindGen->windGenerate(mWindBuf, mWindBufSamples), mWindBufBytes, |