소스 검색

Fixed looping bug, maybe

Josh Yelon 18 년 전
부모
커밋
2443e6c76a
1개의 변경된 파일4개의 추가작업 그리고 2개의 파일을 삭제
  1. 4 2
      panda/src/audiotraits/fmodAudioSound.cxx

+ 4 - 2
panda/src/audiotraits/fmodAudioSound.cxx

@@ -117,8 +117,10 @@ FmodAudioSound(AudioManager *manager, Filename file_name, bool positional) {
     fmod_audio_errcheck("createSound (blank)", result);
   }
 
-  result->setMode(FMOD_LOOP_OFF);  
-  result->setLoopCount(-1);
+  // Some WAV files contain a loop bit.  This is not handled
+  // consistently.  Override it.
+  _sound->setMode(FMOD_LOOP_OFF);
+  _sound->setLoopCount(-1);
   
   //This is just to collect the defaults of the sound, so we don't
   //Have to query FMOD everytime for the info.