Log in

View Full Version : Muxing/transcoding seperate audio/video streams in real time while playing


mmebane
17th February 2005, 03:31
Hi there,

I'm currently working on a security application. I have a security camera which outputs two streams, one audio and one video. I need to be able to capture those two streams and mux them and transcode them in real time while playing live.

The video stream is MJPEG, and the audio stream is PCM signed 16-bit, little endian, mono, 8000 Hz.

I have able to use VideoLan Client 0.8.1 to capture the video stream and transcode/save while playing. I can also capture the audio stream and save it as raw data, but VLC doesn't detect the file type and won't play it. According to the VLC docs (chapter 4), it is possible to manually specify the codec, but I haven't been able to find more info about this.

I also have been unable to get VLC to read from seperate video and audio streams - when I go File -> Open Network Stream, I only get the option to specify one stream. I can't seem to find a command-line option for this, either.


I've tried mplayer, but it chokes on my MJPEG stream, complaining that it isn't seekable. I also don't know if it can play and record at the same time.


My goal is to have a front-end which controls the streaming playback/recording and the camera settings.
Another option is to have, say, one instance of VLC which captures the data, transcodes and saves, AND streams it back out on localhost. I could then have a web interface with the VLC Mozilla plugin connect to this.


I would prefer to have this as a Linux-based or cross-platform solution, but I haven't been able to find working Windows-only tools, either. This seems to me like it should be a fairly simple task, so maybe I'm just not looking in the right places.

Any suggestions?

Thanks,
Mitchell Mebane