X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=simgear%2Fsound%2Fsoundmgr_openal.cxx;h=97a1f05c4ff6e9c42606b9911f1a424b7721e0aa;hb=40fc2907a153093f830994519fc6ada40e21ae49;hp=3a0b2979c3a4d841caf11cdddd67518fcd44e8e1;hpb=f83278bd61f271a261a894881a75fe769963aa38;p=simgear.git diff --git a/simgear/sound/soundmgr_openal.cxx b/simgear/sound/soundmgr_openal.cxx index 3a0b2979..97a1f05c 100644 --- a/simgear/sound/soundmgr_openal.cxx +++ b/simgear/sound/soundmgr_openal.cxx @@ -47,6 +47,7 @@ #include using std::string; +using std::vector; extern bool isNaN(float *v); @@ -613,6 +614,10 @@ bool SGSoundMgr::load(string &samplepath, void **dbuf, int *fmt, } #endif + if (format == AL_FORMAT_STEREO8 || format == AL_FORMAT_STEREO16) { + throw sg_io_exception("Warning: STEREO files are not supported for 3D audio effects: " + samplepath); + } + *dbuf = (void *)data; *fmt = (int)format; *sz = (size_t)size;