Zoneminder streaming options
Zoneminder streaming options
Hi,
I'm trying to develop a standalone mobile client to view Zoneminder monitors and events in a WM6 PDA.
After some research on scientific papers, I've found that the better way to stream video on limited bandwidth networks is over UDP with raw encoded with H264 codec.
Could be zoneminder easily configured to stream with these options?
Which configuration of ZM, do you think that have better performance combining the best quality/bandwidth ratio?
Thanks!
I'm trying to develop a standalone mobile client to view Zoneminder monitors and events in a WM6 PDA.
After some research on scientific papers, I've found that the better way to stream video on limited bandwidth networks is over UDP with raw encoded with H264 codec.
Could be zoneminder easily configured to stream with these options?
Which configuration of ZM, do you think that have better performance combining the best quality/bandwidth ratio?
Thanks!
- zoneminder
- Site Admin
- Posts: 5215
- Joined: Wed Jul 09, 2003 2:07 pm
- Location: Bristol, UK
- Contact:
- zoneminder
- Site Admin
- Posts: 5215
- Joined: Wed Jul 09, 2003 2:07 pm
- Location: Bristol, UK
- Contact:
I have never tried it so I don't have any particular suggestions. Your options are grabbing images to disk and pointing the streamer at those, if the streamer supports streamed images directly you could point it at a zms url. Or you could write a simple script (in perl) using the ZM perl libraries to continuous extract images from memory and pass them to the streamer. It's something i need to look at I think so I have a better idea of how those things work.
Phil
Try http://www.live555.com/punk_ecas wrote:Any suggestion to use third party encoder?
Are you talking about get zms stream into ffserver, for example?
Or there is a better way, like ffserver source coming for shared memory?
- zoneminder
- Site Admin
- Posts: 5215
- Joined: Wed Jul 09, 2003 2:07 pm
- Location: Bristol, UK
- Contact:
Hi Philzoneminder wrote:I'd not heard of that. That looks pretty interesting and I will have a bit of a better look tomorrow if I can.
OpenRTSP is part of live555. I have used openrtsp to decode the rtsp stream from various cameras succesfully, then pipe to ffmpeg. May be you can look deeper the features of OpenRTSP. OpenRTSP is easy to compile, there is not necesary to install, so we use under /usr/bin and so on. It is fast, and has various command lines switches to increase buffer size, etc.
Please, see this post http://www.zoneminder.com/forums/viewtopic.php?t=12583
and if you can, look the PMs at my inbox. You will see various tests we have run succesfully.
Regards
Thanks for the suggestion.Normando wrote:Try http://www.live555.com/punk_ecas wrote:Any suggestion to use third party encoder?
Are you talking about get zms stream into ffserver, for example?
Or there is a better way, like ffserver source coming for shared memory?
By now I'm working on the mobile app, trying to get stream directly from zms, if I can't get a good QoS with that, I will try this media server.
I tried to make slight modification for zm_xxx_camera.cpp to capture then stream it as rtp/udp. the streamed rtp/udp then played by vlc and (then) can be restreamed as rtsp.zoneminder wrote:At the moment you can't configure ZM to stream over UDP, you would need to feed ZM streams into a third party encoder such as ffserver or Darwin Streaming Server etc.
I know this chain udp_from_zmc -> rtsp_from_vlc -> end_player is a resource-chain-hog, but it is better than http_from_zms ->rtsp_from_vlc -> end_player .
I also looked at live555 and libvlc-vmem (is this possible to make zm_vlc_camera from libvlc vmem ?) for more efficient streaming chain, but they are still too hard for me to understand
Here is the patch for ZM to stream over RTP/UDP.
Code: Select all
REMOVED due to slow down page load (i'm on gprs) and patch has been emailed to Phil
cd ZoneMinder-1.24.1
patch -Np1 < /path/to/above-code.patch
update:
- make sure sdp_filename is exists and httpd user (www-data/nobody/apache) has write access on it
if streaming to multicast address make sure to add route to multicast on your network interface route add -net 224.0.0.0 netmask 240.0.0.0 dev ethx
Last edited by azir on Fri May 08, 2009 4:45 pm, edited 2 times in total.
- zoneminder
- Site Admin
- Posts: 5215
- Joined: Wed Jul 09, 2003 2:07 pm
- Location: Bristol, UK
- Contact:
- zoneminder
- Site Admin
- Posts: 5215
- Joined: Wed Jul 09, 2003 2:07 pm
- Location: Bristol, UK
- Contact:
I think the BB has screwed with your patch a bit. For instance look at the line containing the av_set_parameters call. I think anything with a less than or greater than is open to being mangled. Check you disabled html in your post (you may have to repost) or even better maybe provide a linke tpo a patch file or mail it to me (and I will host it) or even put it on the Wiki.
Phil
Something like this would be excellent!
Would the work done with xlib_shm be of any help? This also grab images directly from Zoneminder (as far as I understand it).
Would the work done with xlib_shm be of any help? This also grab images directly from Zoneminder (as far as I understand it).
- zoneminder
- Site Admin
- Posts: 5215
- Joined: Wed Jul 09, 2003 2:07 pm
- Location: Bristol, UK
- Contact:
Azir has kindly mailed me the patch and I have put it up here if anyone would like to try it.
I will be testing it and looking at merging it (or something similar) into the main trunk shortly.
I will be testing it and looking at merging it (or something similar) into the main trunk shortly.
Phil