Created
October 10, 2014 00:01
-
-
Save ivarprudnikov/ae2bbaaae80aa60a1eb2 to your computer and use it in GitHub Desktop.
Streaming MxPEG from Mobotix IP camera via VLC
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// hepful links | |
https://wiki.videolan.org/MxPEG/ | |
http://stackoverflow.com/questions/1735933/streaming-via-rtsp-or-rtp-in-html5 | |
http://en.wikipedia.org/wiki/Internet_media_type | |
http://www.videolan.org/doc/videolan-howto/en/ch09.html | |
http://www.videolan.org/doc/streaming-howto/en/ch03.html | |
http://www.mobotix.com/eng_GB/Support/User-Forum/Applications/Putting-Mobotix-live-video-stream-on-a-Web-site-How-To | |
http://www.linuxquestions.org/questions/linux-desktop-74/how-to-stream-a-webcam-to-http-with-vlc-929319/ | |
// run ubuntu via docker | |
////////////////////////// | |
boot2docker up | |
$(boot2docker shellinit) | |
docker run -p 8080:8080 -t -i ubuntu /bin/bash | |
// run on ubuntu | |
////////////////////// | |
apt-get update | |
apt-get install vlc browser-plugin-vlc libav-tools | |
useradd user | |
// then run one from following commands: | |
>>>>> FLV with duplicate stream | |
sudo -u user vlc-wrapper --ffmpeg-format=mxg -vvv "http://username:password@cameraip:port/cgi-bin/faststream.jpg?stream=full" --sout '#transcode{vcodec=FLV1,vb=800,ab=32,fps=16,width=640,height=480,acodec=none}:duplicate{dst=std{access=http{mime=video/x-flv},mux=ffmpeg{mux=flv},dst=:8080/stream.flv},dst=display}' | |
>>>>> mpg via duplicate stream | |
sudo -u user vlc-wrapper --avformat-format=mxg -vvv "http://username:password@cameraip:port/cgi-bin/faststream.jpg?stream=MxPEG" --sout '#transcode{vcodec=mp4v,vb=800,ab=32,fps=16,width=640,height=480,acodec=none}:duplicate{dst=std{access=http{mime=video/mpeg},mux=ts,dst=:8080/stream.mpg},dst=display}' | |
>>>>> mpg single stream | |
sudo -u user vlc-wrapper --avformat-format=mxg -vvv "http://username:password@cameraip:port/cgi-bin/faststream.jpg?stream=MxPEG" --sout '#transcode{vcodec=mp4v,vb=800,ab=32,fps=16,width=640,height=480,acodec=none}:standard{access=http{mime=video/mpeg},mux=ts,dst=:8080/stream.mpg}' | |
>>>>> OGG | |
sudo -u user vlc-wrapper --avformat-format=mxg -vvv "http://username:password@cameraip:port/cgi-bin/faststream.jpg?stream=full" --sout '#transcode{vcodec=theo,vb=800,scale=1,width=640,height=480,acodec=none}:standard{access=http{mime=video/ogg},mux=ogg,dst=:8080/stream.ogg}' | |
// open stream url: | |
// $(boot2docker ip 2>/dev/null) gives ip of instance which is running docker | |
open http://$(boot2docker ip 2>/dev/null):8080/stream.ogg | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi,
Thank you for the command line.
Do you have an example for a streaming "mjpeg" only ?
Change --ffmpeg-format=mjpeg - --avformat-format=mjpeg
this is correct ?
Thank
Clem