2 ms·
This seems like an odd way to do music streaming, I feel like you'd be better off dumping MP3 files in a folder and taking advantage of the media streaming supp
by cbhl 13y ago
This seems like an odd way to do music streaming, I feel like you'd be better off dumping MP3 files in a folder and taking advantage of the media streaming support in nginx or Apache or similar.
Or, you can look at psobot's implementation of a streaming music app in forever.fm (http://blog.petersobot.com/introducing-forever-fm http://blog.petersobot.com/introducing-forever-fm). The short version of it is that he uses a Python generator to generate frames, passes them through LAME, and then has Tornado hand out the music one frame at a time.