XBMC Addon
XBMC Addon
If there are any ZoneMinder users out there that also use XBMC, you should be able to download an XBMC addon I released recently which allows you to watch streams from your ZoneMinder cameras in XBMC.
You need to be using the (currently beta) XBMC Dharma or newer release to have access to addons. To get the addon, in XBMC just go to Settings, Add-ons, Get Add-ons, XBMC.org Add-ons, Video Add-ons, ZoneMinder. Click on the addon and then click Install.
Once installed, it'll show up under the Videos main menu in the Video Add-ons folder. You can configure the addon to connect to a ZoneMinder server, with configurable cgi and zm paths, and also select the authentication type (plain and hashed authentication are supported).
I'd be especially interested if anyone's able to give the authentication a good thrashing. Hashed authentication seems to work, but at one point adding the IP to the hash was causing problems for me and I never got to the bottom of it. If you have any feedback, please post to this thread.
You need to be using the (currently beta) XBMC Dharma or newer release to have access to addons. To get the addon, in XBMC just go to Settings, Add-ons, Get Add-ons, XBMC.org Add-ons, Video Add-ons, ZoneMinder. Click on the addon and then click Install.
Once installed, it'll show up under the Videos main menu in the Video Add-ons folder. You can configure the addon to connect to a ZoneMinder server, with configurable cgi and zm paths, and also select the authentication type (plain and hashed authentication are supported).
I'd be especially interested if anyone's able to give the authentication a good thrashing. Hashed authentication seems to work, but at one point adding the IP to the hash was causing problems for me and I never got to the bottom of it. If you have any feedback, please post to this thread.
Glad you like it! You're more than welcome to put it in the Wiki.
Unfortunately, I wasn't able to work out how to create a montage. As I wanted a montage myself, I ended up figuring out how to use VLC to create Webcam streams and generate a montage from them, and wrote another XBMC plugin to make connecting to VLC streams easy. I haven't released the plugin yet, but may do at sometime in the future.
Unfortunately, I wasn't able to work out how to create a montage. As I wanted a montage myself, I ended up figuring out how to use VLC to create Webcam streams and generate a montage from them, and wrote another XBMC plugin to make connecting to VLC streams easy. I haven't released the plugin yet, but may do at sometime in the future.
You can do it by building a mosaic with VLM. Here's a Wiki page describing the process:
http://wiki.videolan.org/Mosaic
And here's how I create my montage:
Create the file /etc/vlc/vlm.conf, with contents:
In my example, I've also setup a background at /etc/vlc/background.png so that if any cameras are turned off there's something interesting to see (I used an aerial picture of my house from google Earth).
Now we need to run VLC and tell it to a) use the config file we created and b) create our mosaic. We do this with:
Now we should have a montage, or mosaic, available over HTTP on port 8080, and our separate cameras available on HTTP from port 8081 onwards. We also have our cameras available on MMS, from port 8181. Of course, remember to change 192.168.1.1 to the IP of the machine you're running VLC on.
If you're interested in doing this, and in having an XBMC plugin to easily connect to your streams, just let me know and I'll look into submitting the plugin to the official XBMC repo.
http://wiki.videolan.org/Mosaic
And here's how I create my montage:
Create the file /etc/vlc/vlm.conf, with contents:
Code: Select all
new channel0 broadcast enabled
setup channel0 input v4l2:///dev/video0
setup channel0 output #transcode{vcodec=mp2v,vb=5000,acodec=none}:duplicate{dst=mosaic-bridge{id=0,height=480,width=640},dst=std{access=http,mux=ts,dst=192.168.1.1:8081},dst=std{access=mmsh,mux=asfh,dst=192.168.1.1:8181},select=video}
new channel1 broadcast enabled
setup channel1 input v4l2:///dev/video1
setup channel1 output #transcode{vcodec=mp2v,vb=5000,acodec=none}:duplicate{dst=mosaic-bridge{id=1,height=480,width=640},dst=std{access=http,mux=ts,dst=192.168.1.1:8081},dst=std{access=mmsh,mux=asfh,dst=192.168.1.1:8181},select=video}
new channel2 broadcast enabled
setup channel2 input v4l2:///dev/video2
setup channel2 output #transcode{vcodec=mp2v,vb=5000,acodec=none}:duplicate{dst=mosaic-bridge{id=2,height=480,width=640},dst=std{access=http,mux=ts,dst=192.168.1.1:8082},dst=std{access=mmsh,mux=asfh,dst=192.168.1.1:8182},select=video}
new channel3 broadcast enabled
setup channel3 input v4l2:///dev/video3
setup channel3 output #transcode{vcodec=mp2v,vb=5000,acodec=none}:duplicate{dst=mosaic-bridge{id=3,height=480,width=640},dst=std{access=http,mux=ts,dst=192.168.1.1:8083},dst=std{access=mmsh,mux=asfh,dst=192.168.1.1:8183},select=video}
new background broadcast enabled
setup background input fake://
setup background output #transcode{sfilter=mosaic,vcodec=mp2v,vb=5000,scale=1,acodec=none}:bridge-in{delay=400,id-offset=100}:standard{access=http,mux=ts,dst=192.168.1.1:8085}
control background play
control channel0 play
control channel1 play
control channel2 play
control channel3 play
Now we need to run VLC and tell it to a) use the config file we created and b) create our mosaic. We do this with:
Code: Select all
cvlc -d -I http --http-host 192.168.1.1:8080 --vlm-conf /etc/vlc/vlm.conf --fake-file /etc/vlc/background.png --fake-aspect-ratio "4:3" --mosaic-width 1280 --mosaic-height 960 --mosaic-keep-picture --mosaic-rows 2 --mosaic-cols 2 --mosaic-position 1 --mosaic-order 0,1,2,3
If you're interested in doing this, and in having an XBMC plugin to easily connect to your streams, just let me know and I'll look into submitting the plugin to the official XBMC repo.
Last edited by markhoney on Thu Nov 25, 2010 9:17 am, edited 1 time in total.
Yeah I deduced that and another few typos you have in there, but I can't get it working.
Also, do I have to transcode everything? How is the load on your machine with 4 cameras? I will need a mosaic of 23, hehe. Is it posible to have the mosaic and clic any feed to get full screen and then go back to mosaic?
Thanks for your help
Also, do I have to transcode everything? How is the load on your machine with 4 cameras? I will need a mosaic of 23, hehe. Is it posible to have the mosaic and clic any feed to get full screen and then go back to mosaic?
Thanks for your help
Re: XBMC Addon
Hi everybody !!
I have A machine with debian, no X11, and vlc-nox (vlc with no X11 version) installed and working . The idea is to build in this machine a viewer to read the jpeg stream from monitor 1 from the zm server.
I tested it in vlc for windows and can successfully play the monitor with this source:
http://zmbox_ip/cgi-bin/nph-zms?mode=jpeg&monitor=4&scale=100&user=admin&pass=password
but when I try to open it in vlc-nox, it says it cant find the jpeg stream.
I suspect I have to add some options in linux....
thanks for the help
I have A machine with debian, no X11, and vlc-nox (vlc with no X11 version) installed and working . The idea is to build in this machine a viewer to read the jpeg stream from monitor 1 from the zm server.
I tested it in vlc for windows and can successfully play the monitor with this source:
http://zmbox_ip/cgi-bin/nph-zms?mode=jpeg&monitor=4&scale=100&user=admin&pass=password
but when I try to open it in vlc-nox, it says it cant find the jpeg stream.
I suspect I have to add some options in linux....
thanks for the help
Re: XBMC Addon
I finally got it working by using mplayer on the debian lenny viewer low resources compaq deskpro 2000 machine (Pentium 233Mhz MMX, 128MB RAM, 800MB Hard Disk)
Here are the mplayer options
mplayer -ni -nobps -slave -nocache "http://10.10.10.202/cgi-bin/nph-zms?mod ... format=asf"
My viewer now is showing the mpeg stream at 7fps 640x480 x RGB24 fullscreen at only 35% and 80MB RAM , so I suppoused a P1 100Mhz could be used as a viewer too.
Now my goal is to reduce the CPU, memory and hard disk usage, to get a fully functional viewer with older pcs so we can recicle them !!!!!.
Here are the mplayer options
mplayer -ni -nobps -slave -nocache "http://10.10.10.202/cgi-bin/nph-zms?mod ... format=asf"
My viewer now is showing the mpeg stream at 7fps 640x480 x RGB24 fullscreen at only 35% and 80MB RAM , so I suppoused a P1 100Mhz could be used as a viewer too.
Now my goal is to reduce the CPU, memory and hard disk usage, to get a fully functional viewer with older pcs so we can recicle them !!!!!.