问题
Is there any way to play MP3 directly from a memory stream (without any temp. files) using VB.NET or C#? or play from SQLCe database?
Thanks
回答1:
I'll suggest you try Mp3Sharp. It is a port of JavaLayer and it is written in C#. I am currently using it and SlimDX to play ShoutCast Mp3 streams. So far it works very well.
There is an Mp3Stream class which you use to read the stream and return a predetermined number of PCM bytes. You can write those bytes to a DirectSound buffer for playback if you wish.
回答2:
IrrKlang can also do this for you.
来源:https://stackoverflow.com/questions/3353562/play-mp3-from-stream