Author Topic: Gapless mp3 loop?  (Read 1918 times)

lnBetween

  • Member
  • **
  • Posts: 59
  • Karma: +0/-0
    • View Profile
Gapless mp3 loop?
« on: Thu, Jul 14, 2011 »
I'm trying to loop a mp3 but there's always a gap even though it loops flawlessly in Winamp.

I've also followed Photonstorm post here but there's still a gap when looping...
http://forums.flixel.org/index.php/topic,2964.msg17965.html#msg17965

Any help would be greatly appreciated!!

chiguire

  • Member
  • **
  • Posts: 26
  • Karma: +0/-0
    • View Profile
    • My Personal Site
Re: Gapless mp3 loop?
« Reply #1 on: Fri, Jul 15, 2011 »
I had similar problems like the ones described in that thread. The solutions are also what you find when Googling. So:

a) I don't know about the FlxG.play funcion, but it seems that does the low-level sound hack to gaplessly loop MP3 files.
b) MP3Loop works. I used it and could play gapless loops.
c) I don't know about putting your WAV in a Flash CS4 file, but it worked for photonstorm, so you should try that one too.

lnBetween

  • Member
  • **
  • Posts: 59
  • Karma: +0/-0
    • View Profile
Re: Gapless mp3 loop?
« Reply #2 on: Sat, Jul 16, 2011 »
I've been able to do it by loading a Wav instead of mp3...
Thanks!

KWarp

  • Active Member
  • ***
  • Posts: 105
  • Karma: +0/-0
  • Game Programmer
    • View Profile
    • kwarp.com
Re: Gapless mp3 loop?
« Reply #3 on: Sat, Jul 16, 2011 »
MP3 files automatically insert 20ms of silence at the beginning of their files. It's part of the encoding and cannot be worked around.
To understand recursion, you must first understand recursion.