]> git.mxchange.org Git - simgear.git/blobdiff - simgear/sound/sample_openal.cxx
Oops, ALUT 1.0 requires a little more work than expected.
[simgear.git] / simgear / sound / sample_openal.cxx
index c616bdc843725792ff406368827f7391c3ba0695..c182e829c041bc135e53ec970c3b0b12d8ea59ab 100644 (file)
@@ -107,8 +107,9 @@ SGSoundSample::SGSoundSample( const char *path, const char *file,
 
   buffer = alutCreateBufferFromFile(samplepath.c_str());
   if (buffer == AL_NONE) {
+     ALenum error = alutGetError ();
      print_openal_error("constructor (alutCreateBufferFromFile)");
-     throw sg_exception("Failed to load wav file.");
+     throw sg_exception("Failed to load wav file: "+string(alutGetErrorString (error)));
   }
 
 #else