I’m working on some code to play shoutcast streams and I’m not getting the expected results. I’m getting hissing sound.
Is it possible someone can provide a quick snippet of playing MP3 data using the FSOUND_Stream_Create method.
I can post reproduceable code if needed.
- hjb417 asked 9 years ago
solution found 😀
1) Create a WebRequest & WebResponse to receive the shoutcast mp3 stream
2) use Mp3Sharp @ http://www.robburke.net/mle/mp3sharp/ to decompress the shoutcast stream to PCM
3) send the decompressed audio to the buffer in the FSOUND_Stream_Create
reference code @ http://www.codeproject.com/KB/audio-vid … ipper.aspx
Also, this is what my stream callback delegate looks like:
delegate sbyte StreamCallback(IntPtr stream, IntPtr buff, int len, IntPtr userdata);
I use Convert.ToSByte(true) or Convert.ToSByte(false) to determine if I’m at the end of the stream.
This should probably be a sticky since the CE port of FMOD 3.75 does not support the FSOUND_Stream_Net_XXX functions.
I really love the FMOD CE library!!!! I wouldn’t have been able to get my project off the ground w/o it.
Please login first to submit.