Search code examples
streamingvideo-streamingaudio-streamingmjpeg

MJPG streaming with audio


I have a program on the server side that keeps generating a series of JPEG files, and I want to play these files on the client browser as a video stream, with a desired frame rates (this video should be playing while the new JPEG files are being generated). Meanwhile, I have a wav file that is handy and I want to play this wav file in the client side, when the streaming video is being played.

Is there anyway to do it? I have done a plenty of research but can't find a satisfactory solution -- they are either just for video streaming or just for audio streaming.

I know mjpg-streamer at http://sourceforge.net/projects/mjpg-streamer/ is capable of playing streaming videos in MJPG format from JPEG files, but it doesn't look like that it can play streaming audios.

I am very new to this area, so more detailed explanation will be extremely appreciated. Thank you so much!!!

P.S. a solution/library in C++ is preferred but anything else would help as well. I am working on linux.


Solution

  • I figured it out. The proper way of doing it is to use ffmpeg, libav and an RTMP server, such as red5.