sound error in hxcpp 2.0.6.1

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

sound error in hxcpp 2.0.6.1

m5no1
hi all!
A sound would stop in 3-4 second on iphone. if I turn off GC,"cpp.vm.Gc(false)",every thing runs well.It seems similar to the bug with  ByteArray.readFile in version 2.0.6.0.

Reply | Threaded
Open this post in threaded view
|

Re: sound error in hxcpp 2.0.6.1

m5no1
It seem cause by some thing havn't been implement,i add this to sound.mm  ,it works.
  bool isComplete() {
          ALint state;
          alGetSourcei(mSourceID, AL_SOURCE_STATE, &state);
      return (state == AL_STOPPED);
   }

   void stop()
   {
      alSourceStop(mSourceID);
   }