8

I want to transcode MJPEG stream that comes from IP camera (http://xx.yy.zz.tt:8080/video.cgi) to FLV or MP4 stream under Linux OS so that users can play the file using a web based Flash player such as Flowplayer.

I discovered VLC for that purpose but I cannot figure out the exact command line string. I also need HTTP authentication feature since IP camera access is password protected.

I also interested in any non-VLC solution if any (ffmpeg?).

Anthon
  • 78,313
  • 42
  • 165
  • 222
Emre Yazici
  • 589
  • 2
  • 4
  • 16

3 Answers3

2

I suggest using Handbrake. It makes a nice front end to VLC transcoding.

bahamat
  • 38,658
  • 4
  • 70
  • 103
2

Try this: (On Linux) ffmpeg -f mjpeg -r 8 -i *ttp://your_IP_address:port/video.jpg -f flv -vcodec flv -r 25 -b 26000 -s 320x240 /opt/lampp/htdocs/output.flv

1

Use cURL to handle the HTTP request with authentication, and pipe CURL's output to the stdin of ffmpeg to handle transcoding. You can break it into segments or something as needed. If you need a live stream, things get more complicated, and a commercial solution is probably going to be a lot easier to deal with than any of the open source stuff out there.