103 lines
3.5 KiB
Plaintext
103 lines
3.5 KiB
Plaintext
ZoneMinder ONVIF support
|
|
|
|
Copyright (C) 2016 Jan M. Hochstein
|
|
|
|
This program is free software; you can redistribute it and/or
|
|
modify it under the terms of the GNU General Public License
|
|
as published by the Free Software Foundation; either version 2
|
|
of the License, or (at your option) any later version.
|
|
|
|
This program is distributed in the hope that it will be useful,
|
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
GNU General Public License for more details.
|
|
|
|
You should have received a copy of the GNU General Public License
|
|
along with this program; if not, write to the Free Software
|
|
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
|
--------------------------------------------------------------------------
|
|
|
|
1. PURPOSE
|
|
----------
|
|
|
|
The files in this folder and its subfolders add ONVIF support to zoneminder.
|
|
The ONVIF consortium (www.onvif.org) publishes the ONVIF specifications. These
|
|
specifications describe ways of connecting to and communicating with network
|
|
video devices. Hardware and software that adhere to these specifications are
|
|
meant to be interoperable.
|
|
|
|
|
|
2. SUBFOLDERS
|
|
-------------
|
|
|
|
doc/ - Documentation
|
|
modules/ - perl modules necessary for SOAP communication
|
|
proxy/ - perl SOAP proxy modules generated according to the ONVIF
|
|
specifications
|
|
scripts/ - application logic
|
|
wsdl/ - (empty) this is only used during the proxy generation process
|
|
|
|
|
|
3. LICENSE
|
|
----------
|
|
Any files in this folder and its subfolders are published under the same
|
|
license as this file if they do not carry additional license information.
|
|
|
|
|
|
4. PROXY GENERATION
|
|
-------------------
|
|
|
|
SOAP messages use XML format and need to comply to the schema expected by the
|
|
receiver. While it is possible to build messages through string concatenation
|
|
it is impractical for all but testing purposes.
|
|
Here we use SOAP proxy modules generated by the script wsdl2perl.pl from the
|
|
SOAP::WSDL module (http://search.cpan.org/~mkutter/SOAP-WSDL-2.00.10/)
|
|
version 2.00.10.
|
|
|
|
A - Get the input files.
|
|
|
|
Download these files and any web service (.wsdl) or schema (.xsd)
|
|
files referenced therein into the wsdl/ subfolder.
|
|
|
|
http://www.onvif.org/onvif/ver10/device/wsdl/devicemgmt.wsdl
|
|
http://www.onvif.org/onvif/ver10/media/wsdl/media.wsdl
|
|
http://www.onvif.org/onvif/ver20/ptz/wsdl/ptz.wsdl
|
|
http://www.onvif.org/onvif/ver20/analytics/wsdl/analytics.wsdl
|
|
|
|
The complete list of files we have during build is:
|
|
|
|
analytics.wsdl
|
|
b-2.xsd
|
|
bf-2.xsd
|
|
br-2.xsd
|
|
brw-2.wsdl
|
|
bw-2.wsdl
|
|
devicemgmt.wsdl
|
|
media.wsdl
|
|
onvif.xsd
|
|
ptz.wsdl
|
|
r-2.xsd
|
|
rw-2.wsdl
|
|
soap-envelop.xsd
|
|
t-1.xsd
|
|
wsdd-discovery-1.1-schema-os.xsd
|
|
wsdd-discovery-1.1-wsdl-os.wsdl
|
|
wsdiscovery-udp.wsdl
|
|
wsdl11soap12.xsd
|
|
wsdl.xsd
|
|
wsnotification.wsdl
|
|
xmlmime.xsd
|
|
xop-include.xsd
|
|
|
|
B - Generate the proxy modules using these commands.
|
|
|
|
wsdl2perl.pl -p ONVIF::Device:: -b proxy/lib file:wsdl/devicemgmt.wsdl
|
|
wsdl2perl.pl -p ONVIF::Media:: -b proxy/lib file:wsdl/media.wsdl
|
|
wsdl2perl.pl -p ONVIF::PTZ:: -b proxy/lib file:wsdl/ptz.wsdl
|
|
wsdl2perl.pl -p ONVIF::Event:: -b proxy/lib file:wsdl/event.wsdl
|
|
wsdl2perl.pl -p ONVIF::Analytics:: -b proxy/lib file:wsdl/analytics.wsdl
|
|
wsdl2perl.pl -p WSDiscovery:: -b proxy/lib file:wsdl/wsdiscovery-udp.wsdl
|
|
wsdl2perl.pl -p WSNotification:: -b proxy/lib file:wsdl/wsnotification.wsdl
|
|
|
|
I had to tweak SOAP::WSDL a little bit to get correct proxies.
|