aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorJacek Antonelli2009-03-13 21:39:24 -0500
committerJacek Antonelli2009-03-13 21:39:24 -0500
commit7ee91c387e3d530c721a0bbbb2343bbce4b27730 (patch)
treea4957823ea5db5c8785ca03a5ff81cf27c40e7fc
parentDon't find specific OpenAL lib locations on Mac/Linux. (diff)
downloadmeta-impy-7ee91c387e3d530c721a0bbbb2343bbce4b27730.zip
meta-impy-7ee91c387e3d530c721a0bbbb2343bbce4b27730.tar.gz
meta-impy-7ee91c387e3d530c721a0bbbb2343bbce4b27730.tar.bz2
meta-impy-7ee91c387e3d530c721a0bbbb2343bbce4b27730.tar.xz
Added error checking when generating an OpenAL source
Diffstat (limited to '')
-rw-r--r--ChangeLog.txt6
-rw-r--r--linden/indra/llaudio/audioengine_openal.cpp11
2 files changed, 17 insertions, 0 deletions
diff --git a/ChangeLog.txt b/ChangeLog.txt
index dc7712b..38a2c06 100644
--- a/ChangeLog.txt
+++ b/ChangeLog.txt
@@ -1,3 +1,9 @@
12009-03-13 Jacek Antonelli <jacek.antonelli@gmail.com>
2
3 * linden/indra/llaudio/audioengine_openal.cpp:
4 Added error checking when generating an OpenAL source.
5
6
12009-03-12 Jacek Antonelli <jacek.antonelli@gmail.com> 72009-03-12 Jacek Antonelli <jacek.antonelli@gmail.com>
2 8
3 * linden/indra/cmake/OPENAL.cmake: 9 * linden/indra/cmake/OPENAL.cmake:
diff --git a/linden/indra/llaudio/audioengine_openal.cpp b/linden/indra/llaudio/audioengine_openal.cpp
index 8f836a6..6d9a242 100644
--- a/linden/indra/llaudio/audioengine_openal.cpp
+++ b/linden/indra/llaudio/audioengine_openal.cpp
@@ -172,6 +172,17 @@ LLAudioChannelOpenAL::LLAudioChannelOpenAL()
172 mLastSamplePos(0) 172 mLastSamplePos(0)
173{ 173{
174 alGenSources(1, &mALSource); 174 alGenSources(1, &mALSource);
175
176 if( mALSource == AL_NONE )
177 {
178 ALenum error = alGetError();
179 if( error == AL_NO_ERROR )
180 {
181 LL_WARNS("OpenAL") << "LLAudioChannelOpenAL::LLAudioChannelOpenAL() Could not generate mALSource, but no error is indicated!" << LL_ENDL;
182 }
183 LL_WARNS("OpenAL") << "LLAudioChannelOpenAL::LLAudioChannelOpenAL() Could not generate mALSource: (" << error << ") " << alGetString( error ) << LL_ENDL;
184 }
185
175} 186}
176 187
177LLAudioChannelOpenAL::~LLAudioChannelOpenAL() 188LLAudioChannelOpenAL::~LLAudioChannelOpenAL()