Difference between revisions of "Vpipe"

From ZoneMinder Wiki
Jump to navigationJump to search
 
Line 13: Line 13:


Now. with ffmpeg, do something like:
Now. with ffmpeg, do something like:
 
<nowiki>
ffmpeg -i http://<ip_of_your_cam>/img/video.asf -r 8 -f rawvideo - | ./vpipe -f <format> -i 0
ffmpeg -i http://<ip_of_your_cam>/img/video.asf -r 8 -f rawvideo - | ./vpipe -f <format> -i 0
</nowiki>
where 0 mean "/dev/video0"
where 0 mean "/dev/video0"


Now you can simply create a monitor that point to /dev/video1 chan 0 whith the same resolution and color palette of your ffmpeg formatted output, and you get your cam work with zoneminder
Now you can simply create a monitor that point to /dev/video1 chan 0 whith the same resolution and color palette of your ffmpeg formatted output, and you get your cam work with zoneminder
Ther's also a little and crappy daemon written in python to automatize the use of vpipe + vloopback with ffmpeg for multiple cams here:
http://download.astronomix.org/ZMmpeg4.tgz


If you hare on debian sid:
If you hare on debian sid:
 
<nowiki>
deb http://packages.medianix.net/ mercury main
deb http://packages.medianix.net/ mercury main


apt-get/aptitude install vpipe
apt-get/aptitude install vpipe
m-a get vloopback-source
m-a get vloopback-source
</nowiki>

Revision as of 18:01, 2 December 2007

A way to get the stream from mpeg4 only capable ip cams ( or other encoding also ) captured in zm:

This way work better in terms of load and FPS than the method of save a single frame a time with mplayer in jpeg.

You need: - ffmpeg - vloopback (http://www.lavrsen.dk/twiki/bin/view/Motion/VideoFourLinuxLoopbackDevice) - vpipe (http://download.astronomix.org/vpipe-0.0.2.tgz )

compile vloopback and modprobe it to create a v4l loopback device. It create a videoN and videoN+1 couple of devices, /dev/video0 and /dev/video1 for example. In this case, video0 is the input device, and video1 is the output device.

Now. with ffmpeg, do something like: ffmpeg -i http://<ip_of_your_cam>/img/video.asf -r 8 -f rawvideo - | ./vpipe -f <format> -i 0 where 0 mean "/dev/video0"

Now you can simply create a monitor that point to /dev/video1 chan 0 whith the same resolution and color palette of your ffmpeg formatted output, and you get your cam work with zoneminder

Ther's also a little and crappy daemon written in python to automatize the use of vpipe + vloopback with ffmpeg for multiple cams here: http://download.astronomix.org/ZMmpeg4.tgz

If you hare on debian sid: deb http://packages.medianix.net/ mercury main apt-get/aptitude install vpipe m-a get vloopback-source