I embedded an mp3 file be used as background music for my app. Though it works fine, the problem is that it doesn't play the whole track, it just plays the first 32 seconds of it (the mp3 file is 1:30 min).
Does anyone here has any idea why?
I've read here that maybe the sound doesn't fit into the supported flash player sound format, but I don't think that's the problem! The file is not that big, but maybe I am wrong?
Any idea whats causing the problem? Or how to fix it? The code is fine, am sure of it (its pretty simple. Just embedded the mp3, initialized the required variable and played the sound. Nothing fancy)
EDIT: the mp3 is encoded at 44100 KHz
EDIT Here is the code, just incase
package
{
import flash.display.Sprite;
import flash.media.Sound;
import flash.media.SoundChannel;
public class BackgroundMusic extends Sprite
{
[Embed(source="swfs/bg.mp3")]
private var BG:Class;
public function BackgroundMusic()
{
var backgroundMusic:Sound = new BG();
backgroundMusic.play();
}
}
}