I want to add one ByteArray to another, the ByteArray both are extracted form a MP3 sound clip, once I added one to the other, I want to play them as one sound ByteArray with loadCompressedDataFromByteArray, here is the function I wrote, it is not working, why?
private function MergeSoundClips(s1:Sound,s2:Sound):Sound
var _Bytes1:ByteArray = new ByteArray();
s1.extract(_Bytes1, s1.length );
var _Bytes2:ByteArray = new ByteArray();
s2.extract(_Bytes2, s2.length );
_Bytes1.position = 0;
s1.loadCompressedDataFromByteArray ( _Bytes1, _Bytes1.length );