i
ii
2006 MATE Media Access Technologies Ltd. All rights reserved.
The copyright and proprietary rights in the guide belong to MATE – Media Access Technologies. It is
strictly forbidden to copy, duplicate, sell, lend or otherwise use this guide in any way, shape or form
without the prior consent of MATE – Media Access Technologies.
This product is based on software developed by MATE – Media Access Technologies.
Redistribution of this manual and its use binary form (PDF) are permitted, provided that the above
copyright notice and this paragraph are duplicated in all such forms and that any documentation,
advertising materials and other materials related to such distribution and use, acknowledge that the
software was developed by MATE – Media Access Technologies.
THIS SOFTWARE IS PROVIDED “AS IS” AND WITHOUT ANY EXPRESS OR IMPLIED
WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF
MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
Behavior Watch™, Cortex™, Cortex Manager™, BW2004 Client™ and Configuration Manager™
are trademarks of MATE – Media Access Technologies Ltd.
All other trademarks used in this document are the property of their respective owners.
iii
1.1
L
ICENSE
A
GREEMENT
...........................................................................................1
1.2
A
RCHITECTURE
.....................................................................................................1
R
EQUIREMENTS
.....................................................................................................4
2.2
I
NSTALLING THE
S
OFTWARE
.................................................................................4
2.3
U
N
-
INSTALLING THE
S
OFTWARE
...........................................................................5
!! "
#!#$% &
4.1
O
VERVIEW
............................................................................................................7
4.2
T
ERMS AND ACRONYMS
........................................................................................8
4.3
U
SING THE
API .....................................................................................................8
4.3.1 API functions.................................................................................................8
4.3.2 Callbacks.......................................................................................................8
4.3.3 Including Cortex API in your project ...........................................................9
4.4
API
W
ORKFLOW
.................................................................................................10
4.4.1 Step 1: Initialization....................................................................................10
4.4.2 Step 2: Callback Registration .....................................................................10
4.4.3 Step 3: Start CortexAPI ..............................................................................11
4.4.4 Step 4: Stop CortexAPI ...............................................................................11
4.5
API
T
YPES
..........................................................................................................11
4.5.1 MateUtil.AlarmData ...................................................................................11
4.5.2 MU.enDeviceType.......................................................................................12
4.5.3 CrtxApiTypes.ScannerDesc ........................................................................12
4.5.4 CrtxApiTypes.FeedDesc..............................................................................12
4.5.5 ManagedFrameHeader...............................................................................13
4.6
API
FUNCTIONS
...................................................................................................14
iv
4.6.1 Costructor ...................................................................................................14
4.6.2 SetManagerIP .............................................................................................14
4.6.3 CortexApiStart ............................................................................................15
4.6.4 CortexApiStop .............................................................................................15
4.6.5 GetScannersList ..........................................................................................15
4.6.6 GetFeedsList ...............................................................................................16
4.6.7 StartLiveVideo.............................................................................................16
4.6.8 StopLiveVideo .............................................................................................17
4.6.9 SetFeedproperty..........................................................................................17
4.6.10 GetLastAlarms ..........................................................................................18
4.6.11 GetAlarmByAlarmID ................................................................................19
4.6.12 GetMsfList.................................................................................................19
4.6.13 GetMsf.......................................................................................................20
4.6.14 SetMsf........................................................................................................21
4.6.15 DeleteMsf ..................................................................................................22
4.7
API
CALLBACKS
..................................................................................................22
4.7.1 Registration.................................................................................................23
4.7.2 OnConnect ..................................................................................................23
4.7.3 OnDisconnect..............................................................................................23
4.7.4 OnScannerAddRemoved .............................................................................24
4.7.5 OnFeedAddRemoved...................................................................................24
4.7.6 OnAlarmEvent.............................................................................................24
4.7.7 OnAlarmStopEvent .....................................................................................25
4.7.8 OnFrameReady ...........................................................................................25
4.8
L
IVE
V
IDEO
.........................................................................................................26
4.8.1 Selecting video frames format.....................................................................26
4.8.2 Requesting for live video.............................................................................26
4.8.3 Presenting the Video and Layout................................................................26
4.8.4 JpegLayoutToWindow.................................................................................26
4.8.5 RGBLayoutToWindow ................................................................................27
'%()! *
5.1
I
NIT
\C
LOSE
T
AB
..................................................................................................28
5.2
S
YSTEM
I
NFO TAB
...............................................................................................30
5.3
L
IVE
T
AB
............................................................................................................32
5.4
E
VENTS
T
AB
.......................................................................................................33
++,-
is a set of functions that allow a 3
rd
party to develop video and event
management applications that control MATE video analytics servers and edge
devices, set video detection rules and then present video, events and other metadata
received from said servers and devices.
Please read the License Notice before you use the Cortex API software. The use of the
software is only permitted if you agree with this license agreement.
Cortex API is provided with sample code. You will need one video analytics server or
edge device to develop with Cortex API. To deploy your application with multiple
servers / devices you will need the Cortex Server as well.
1.1 License Agreement
MATE – Media Access Technologies (MATE) will grant you a license for the
software contained in this package only under the condition that there is a signed
license agreement (as provided by MATE) , in place for this software. Please make
sure that the license agreement is available and signed and that you act according to
that agreement. If there is no valid license agreement in place, MATE shall not grant
you the license for this software. In this case, please return the whole package
(software and other contents) to MATE.
1.2 Architecture
The figure below describes the main modules of a video analytics and management
system constructed with Cortex API and the data flow. The description refers to
Behavior Watch™: a PC-based video analytics server, but is applicable to embedded
devices such as MATE Trigger™.