RecorderCommandService Class Reference

Through the RecorderCommandService it is possible to send various commands related to PTZ, output handling, recordings, live, and other device related commands. More...

Inheritance diagram for RecorderCommandService:

Classes

class  ClientCapabilities
 ClientCapabilities specifies what the client supports and are exchanged once per multicast session at the MulticastStart() method call. More...
 
class  ImageMask
 Represents a image mask. More...
 
class  JPEGData
 Represents a single JPEG image retrieved from the media database. More...
 
class  LiveStreamDevice
 
class  LiveStreamSetting
 
class  ManualRecordingInfo
 Encapsulates information about manual recording for a device. More...
 
class  ManualRecordingResult
 Represents result of starting and stopping manual recording. More...
 
class  MotionAreaInfo
 Class contains position and size of area with motion. More...
 
class  MotionAreaInfos
 
class  MulticastInfo
 
class  PTZArgs
 
class  PTZPairBoolean
 Represents a named PTZ parameter of boolean type. More...
 
class  PTZPairDouble
 Represents a named PTZ parameter of double type. More...
 
class  PtzSessionInfo
 
class  SequenceEntry
 Represents an entry in a list of sequences. More...
 
class  SequenceType
 Represents a sequence type. More...
 
class  SmartSearchResult
 Represents the smart search result. More...
 
class  SmartSearchStatus
 Represents the smart search status. More...
 
class  TimeDuration
 Represents a timespan (.NET TimeSpan does apparently not work automatically with soap serialization) More...
 
class  TimeLineInformationData
 Class containing time line information data. More...
 
class  UserInfo
 

Public Types

enum  IOState { Unknown , Activated , Deactivated }
 Represents the actual or requested state of an input- or outputdevice. More...
 
enum  SmartSearchStatusType {
  UnspecifiedError , SearchInProgress , SearchResultReady , SearchEndTimeReached ,
  SearchCancelled
}
 Represents the smart search status. More...
 

Public Member Functions

void ControlLiveStream (string token, Guid clientID, Guid controlID, LiveStreamDevice[] devices)
 
int GetVersion ()
 Returns the protocol version.
 
IOState InputGetState (string token, Guid deviceId)
 Get current I/O state of given input device.
 
ManualRecordingInfo[] IsManualRecording (string token, Guid[] deviceIds)
 This method returns whether manual recording on a device is active or not. Please note that if manual recording on a device is not active (false), it does not necessary mean that the device stopped recording. The device might still record because of other recording rules, just not because of manual recording. If given device is not recognized value sent back for this device is false.
 
JPEGData JPEGGetAt (string token, Guid deviceId, DateTime time)
 Get image from a given device as JPEG, at a given time or the nearest one (either before or after). If no image is available the response is a JPEGData structure with time set to minimum dateTime, and data set to nothing.
 
JPEGData JPEGGetAtOrAfter (string token, Guid deviceId, DateTime time)
 Get image from a given device as JPEG, at a given time or nearest image after. If no image is available the response is a JPEGData structure with time set to minimum dateTime, and data set to nothing.
 
JPEGData JPEGGetAtOrBefore (string token, Guid deviceId, DateTime time)
 Get image from a given device as JPEG, at a given time or nearest image before. If no image is available the response is a JPEGData structure with time set to minimum dateTime, and data set to nothing.
 
JPEGData JPEGGetLive (string token, Guid deviceId, int maxWidth, int maxHeight)
 Get live image from a given device as JPEG (i.e. encoded from last keyframe). If no image is available the response is a JPEGData structure with time set to minimum dateTime, and data set to nothing.
 
void MulticastContinue (string token, Guid[] multicastSessionIds)
 Keeps the multicast of live stream alive. Must be called periodically to keep the multicast alive with no larger intervals than specified by MulticastInfo.
 
MulticastInfo[] MulticastStart (string token, Guid[] deviceIds, ClientCapabilities clientCapabilities)
 Start multicast of live stream.
 
void MulticastStop (string token, Guid[] multicastSessionIds)
 Stop multicast of live stream.
 
void OutputActivate (string token, Guid deviceId)
 Activate a given output device.
 
void OutputDeactivate (string token, Guid deviceId)
 Deactivate a given output device.
 
IOState OutputGetState (string token, Guid deviceId)
 Get current I/O state of given output device.
 
void OutputTrigger (string token, Guid deviceId, TimeDuration duration)
 Trigger output to activate for a given time period and then automatically deactivate.
 
string[] PresetGetList (string token, Guid deviceId)
 Get list of presets for a given device.
 
void PresetMoveTo (string token, Guid deviceId, string presetName)
 Request device to move to a given named preset.
 
void PresetSet (string token, Guid deviceId, string presetName)
 Reserved for future use (Not implemented yet).
 
void PTZActivatePatrollingSchema (string token, Guid deviceId, Guid patrollingSchemaId)
 
void PTZCenter (string token, Guid deviceId, double refWidth, double refHeight, double centerX, double centerY, double zoom)
 Request PTZ device to center around a given point.
 
PTZArgs PTZGetAbsolutePosition (string token, Guid deviceId)
 Get absolute PTZ position of device.
 
PtzSessionInfo PTZGetSessionInfo (string token, Guid deviceId)
 
void PTZMoveAbsolute (string token, Guid deviceId, PTZArgs ptzArgs)
 Request device to move to specified absolute PTZ position.
PTZArgs details:

 
void PTZMoveHome (string token, Guid deviceId)
 Request device to move to home position (as defined by the device itself)
 
void PTZMoveRelative (string token, Guid deviceId, PTZArgs ptzArgs)
 The 'PTZMoveRelative' command move the specific camera in the given direction - one time.
PTZArgs details:

 
void PTZMoveStart (string token, Guid deviceId, PTZArgs ptzArgs)
 Start move with given speed parameters. Movement will continue until a PTZMoveStop or some other command is received. PTZArgs details:

 
void PTZMoveStop (string token, Guid deviceId)
 Request device to stop a current move operation (started with PTZMoveStart)
 
void PTZRectangle (string token, Guid deviceId, double refWidth, double refHeight, double left, double top, double bottom, double right)
 Request PTZ device to show a specified rectangle.
 
void PTZReleaseSession (string token, Guid deviceId)
 
void PTZReserveSession (string token, Guid deviceId)
 
 RecorderCommandService ()
 RecorderCommandService is used to control XProtect recorder, and to retrieve information about device recordings.
 
void SendDriverCommand (string token, Guid deviceId, string command)
 
SequenceEntry[] SequencesGet (string token, Guid deviceId, Guid sequenceType, DateTime minTime, DateTime maxTime, int maxCount)
 Get chronological list of sequences for a given sequence type with specified minimum time, maximum time and maximum count. Sequences are processed onwards from minTime and are sorted by TimeBegin.
 
SequenceEntry[] SequencesGetAround (string token, Guid deviceId, Guid sequenceType, DateTime centerTime, int maxCountBefore, int maxCountAfter)
 Get chronological list of sequences for a given sequence type with specified center time, maximum count before center time and maximum count after center time. A sequence with TimeBegin equal to centertime will increase "after" count.
 
SequenceEntry[] SequencesGetAroundWithSpan (string token, Guid deviceId, Guid sequenceType, DateTime centerTime, TimeDuration maxTimeBefore, int maxCountBefore, TimeDuration maxTimeAfter, int maxCountAfter)
 Get chronological list of sequences for a given sequence type with specified center time, maximum count before center time and maximum count after center time. Furthermore, search is limited before and after centertime by maximum timespans.
 
SequenceType[] SequencesGetTypes (string token, Guid deviceId)
 Get list of available sequence types for a given device.
 
void SmartSearchCancel (string token, Guid smartSearchId)
 Cancels a specified smart search operation.
 
SmartSearchResult SmartSearchGetResult (string token, Guid smartSearchId, bool continueSearch)
 Return the result a specified smart search operation.
 
SmartSearchStatus SmartSearchGetStatus (string token, Guid smartSearchId)
 Return the status of a specified smart search operation.
 
Guid SmartSearchStart (string token, Guid deviceId, DateTime searchBeginTime, DateTime searchEndTime, int sensitivity, TimeDuration searchInterval, ImageMask searchMask, bool ignoreInitialMotion, System.Drawing.Size resultMotionMaskSize)
 Starts a smart serch operation on the server.
 
ManualRecordingResult[] StartManualRecording (string token, Guid[] deviceIds)
 This method requests a start of manual recording on a device. The start manual recording request will start recording on the device if recording has not already been started because of other rules: A service channel event is sent when the evaluation of start manual recording has been made. If manual recording is already active, the command is simply ignore but the request is still successful.
 
bool StartRecording (string token, Guid deviceId, long recordingTimeMicroSeconds)
 This method is only supported by E-Code family. For manual recording use StartManualRecording.
 
ManualRecordingResult[] StopManualRecording (string token, Guid[] deviceIds)
 This method requests a stop of manual recording on a device. Please note that stopping manual recording does not necessary mean that the device stops recording. The device might still record because of other recording rules, just not because of manual recording. A service channel event is sent when the evaluation of stop manual recording has been made. If manual recording is already stopped, the command is simply ignore but the request is still successful.
 
TimeLineInformationData[] TimeLineInformationGet (string token, Guid deviceId, Guid[] timeLineInformationTypes, DateTime timeLineInformationBeginTime, TimeDuration timeLineInformationInterval, int timeLineInformationCount)
 Gets specified timeline information.
 

Detailed Description

Through the RecorderCommandService it is possible to send various commands related to PTZ, output handling, recordings, live, and other device related commands.

All commands may return an ErrorNumber and possibly a SubErrorNumber in the SOAP response in case the request fails.
The ErrorNumber and SubErrorNumber are returned in the SOAP fault details as two XML elements.
The following error numbers are possible:

Error number Description
10000 General communication error.
10001 SOAP version is not supported.
10002 SOAP message is invalid.
10003 SOAP version could not be recognized.
20001 There is a problem with the specified security token.
40000 An error occurred while executing this method.
40295 A PTZ error occurred. For possible sub error numbers, see example for PTZMoveAbsolute

Error number 20001 indicates a problem with the security token and will be followed by one of these sub error numbers:

Sub error number Description
1 Occurs when no token was specified by the client.
2 Occurs when the validation of the supplied token failed.
3 Occurs when the supplied token had expired.
4 Occurs when the supplied token could not be validated at the moment of the request; the client should retry later.


As an example on the SOAP communication see the following SOAP request and response for the InputGetState command:
SOAP request (notice the missing token):

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<soap:Body>
<InputGetState xmlns="http://videoos.net/2/XProtectCSRecorderCommand">
<token></token>
<deviceId>b43d5369-6a4e-4364-ba2d-20b3a5814146</deviceId>
</soap:Body>
</soap:Envelope>
IOState InputGetState(string token, Guid deviceId)
Get current I/O state of given input device.
Definition RecorderCommandService.cs:1332

SOAP response:

<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>
<soap:Fault>
<faultcode>soap:Server</faultcode>
<faultstring>No token supplied</faultstring>
<detail>
<ErrorNumber>20001</ErrorNumber>
<SubErrorNumber>1</SubErrorNumber>
</detail>
</soap:Fault>
</soap:Body>
</soap:Envelope>

Member Enumeration Documentation

◆ IOState

Represents the actual or requested state of an input- or outputdevice.

Enumerator
Unknown 

I/O state is unknown.

Activated 

I/O state is activated.

Deactivated 

I/O state is deactivated.

◆ SmartSearchStatusType

Represents the smart search status.

Enumerator
UnspecifiedError 

Unspecified error. Search has stopped.

SearchInProgress 

The smart search is in progress.

SearchResultReady 

Search result ready.

SearchEndTimeReached 

Search end time reached.

SearchCancelled 

The search has been cancelled.

Constructor & Destructor Documentation

◆ RecorderCommandService()

RecorderCommandService.RecorderCommandService ( )
inline

RecorderCommandService is used to control XProtect recorder, and to retrieve information about device recordings.

Construction can be done like:

String serverUri = String.Format("http://{0}:{1}/RecorderCommandService/RecorderCommandService.asmx", recorderAddress, recorderPort);
rcs.Url = serverUri;
Through the RecorderCommandService it is possible to send various commands related to PTZ,...
Definition RecorderCommandService.cs:108
RecorderCommandService()
RecorderCommandService is used to control XProtect recorder, and to retrieve information about device...
Definition RecorderCommandService.cs:121

All methods require a token as a parameter. The token is returned on the Login method on the ServerCommandService.

Member Function Documentation

◆ ControlLiveStream()

void RecorderCommandService.ControlLiveStream ( string token,
Guid clientID,
Guid controlID,
LiveStreamDevice[] devices )
inline

◆ GetVersion()

int RecorderCommandService.GetVersion ( )
inline

Returns the protocol version.

Returns
the protocol version

◆ InputGetState()

IOState RecorderCommandService.InputGetState ( string token,
Guid deviceId )
inline

Get current I/O state of given input device.

Parameters
tokenSecurity token
deviceIdDevice ID
Returns

◆ IsManualRecording()

ManualRecordingInfo[] RecorderCommandService.IsManualRecording ( string token,
Guid[] deviceIds )
inline

This method returns whether manual recording on a device is active or not. Please note that if manual recording on a device is not active (false), it does not necessary mean that the device stopped recording. The device might still record because of other recording rules, just not because of manual recording. If given device is not recognized value sent back for this device is false.

Parameters
tokenSecurity token
deviceIdslist of device Ids for which to check manual recording.
Returns
true if manual recording is activated on the device, otherwise false

◆ JPEGGetAt()

JPEGData RecorderCommandService.JPEGGetAt ( string token,
Guid deviceId,
DateTime time )
inline

Get image from a given device as JPEG, at a given time or the nearest one (either before or after). If no image is available the response is a JPEGData structure with time set to minimum dateTime, and data set to nothing.

Parameters
tokenSecurity token
deviceIdDevice ID
timeRequested image time as UTC
Returns
JPEGData

◆ JPEGGetAtOrAfter()

JPEGData RecorderCommandService.JPEGGetAtOrAfter ( string token,
Guid deviceId,
DateTime time )
inline

Get image from a given device as JPEG, at a given time or nearest image after. If no image is available the response is a JPEGData structure with time set to minimum dateTime, and data set to nothing.

Parameters
tokenSecurity token
deviceIdDevice ID
timeRequested image time as UTC
Returns
JPEGData

◆ JPEGGetAtOrBefore()

JPEGData RecorderCommandService.JPEGGetAtOrBefore ( string token,
Guid deviceId,
DateTime time )
inline

Get image from a given device as JPEG, at a given time or nearest image before. If no image is available the response is a JPEGData structure with time set to minimum dateTime, and data set to nothing.

Parameters
tokenSecurity token
deviceIdDevice ID
timeRequested image time as UTC
Returns
JPEGData

◆ JPEGGetLive()

JPEGData RecorderCommandService.JPEGGetLive ( string token,
Guid deviceId,
int maxWidth,
int maxHeight )
inline

Get live image from a given device as JPEG (i.e. encoded from last keyframe). If no image is available the response is a JPEGData structure with time set to minimum dateTime, and data set to nothing.

Parameters
tokenSecurity token
deviceIdDevice ID
maxWidthThe maximum width, considering aspect ratio
maxHeightThe maximum height, considering aspect ratio
Returns
JPEGData

◆ MulticastContinue()

void RecorderCommandService.MulticastContinue ( string token,
Guid[] multicastSessionIds )
inline

Keeps the multicast of live stream alive. Must be called periodically to keep the multicast alive with no larger intervals than specified by MulticastInfo.

Parameters
tokenSecurity token
multicastSessionIdsArray of multicast session IDs for which multicast live stream should be continued

◆ MulticastStart()

MulticastInfo[] RecorderCommandService.MulticastStart ( string token,
Guid[] deviceIds,
ClientCapabilities clientCapabilities )
inline

Start multicast of live stream.

Parameters
tokenSecurity token
deviceIdsArray of device IDs for which multicast live stream should be started
clientCapabilitiesSpecifies what the client supports. See ClientCapabilities class. This parameter is optional on SOAP level.
Returns
An array of MulticastInfo classes that each contains the multicast connection information for a specific device

◆ MulticastStop()

void RecorderCommandService.MulticastStop ( string token,
Guid[] multicastSessionIds )
inline

Stop multicast of live stream.

Parameters
tokenSecurity token
multicastSessionIdsArray of multicast session IDs for which multicast live stream should be stopped

◆ OutputActivate()

void RecorderCommandService.OutputActivate ( string token,
Guid deviceId )
inline

Activate a given output device.

Parameters
tokenSecurity token
deviceIdDevice ID

◆ OutputDeactivate()

void RecorderCommandService.OutputDeactivate ( string token,
Guid deviceId )
inline

Deactivate a given output device.

Parameters
tokenSecurity token
deviceIdDevice ID

◆ OutputGetState()

IOState RecorderCommandService.OutputGetState ( string token,
Guid deviceId )
inline

Get current I/O state of given output device.

Parameters
tokenSecurity token
deviceIdDevice ID
Returns

◆ OutputTrigger()

void RecorderCommandService.OutputTrigger ( string token,
Guid deviceId,
TimeDuration duration )
inline

Trigger output to activate for a given time period and then automatically deactivate.

Parameters
tokenSecurity token
deviceIdDevice ID
durationDuration in which the output should be activated

◆ PresetGetList()

string[] RecorderCommandService.PresetGetList ( string token,
Guid deviceId )
inline

Get list of presets for a given device.

Parameters
tokenSecurity token
deviceIdDevice ID
Returns
List of named presets

For error handling see example for PTZMoveAbsolute.

◆ PresetMoveTo()

void RecorderCommandService.PresetMoveTo ( string token,
Guid deviceId,
string presetName )
inline

Request device to move to a given named preset.

Parameters
tokenSecurity token
deviceIdDevice ID
presetName

For error handling see example for PTZMoveAbsolute.

◆ PresetSet()

void RecorderCommandService.PresetSet ( string token,
Guid deviceId,
string presetName )
inline

Reserved for future use (Not implemented yet).

Parameters
tokenSecurity token
deviceIdDevice ID
presetName

For error handling see example for PTZMoveAbsolute.

◆ PTZActivatePatrollingSchema()

void RecorderCommandService.PTZActivatePatrollingSchema ( string token,
Guid deviceId,
Guid patrollingSchemaId )
inline

◆ PTZCenter()

void RecorderCommandService.PTZCenter ( string token,
Guid deviceId,
double refWidth,
double refHeight,
double centerX,
double centerY,
double zoom )
inline

Request PTZ device to center around a given point.

Parameters
tokenSecurity token
deviceIdDevice ID
refWidthWidth of the image to center camera in
refHeightHeight of the image to center camera in
centerXHorizontal center position relative to refWidth
centerYVertical center position reletive to refHeight
zoomZoom level are in interval [0-1] and 0=full zoom out; 1=full zoom in; <0=no change.

For error handling see example for PTZMoveAbsolute.

◆ PTZGetAbsolutePosition()

PTZArgs RecorderCommandService.PTZGetAbsolutePosition ( string token,
Guid deviceId )
inline

Get absolute PTZ position of device.

Parameters
tokenSecurity token
deviceIdDevice ID
Returns
PTZ parameters representing the absolute device position

For error handling see example for PTZMoveAbsolute.

◆ PTZGetSessionInfo()

PtzSessionInfo RecorderCommandService.PTZGetSessionInfo ( string token,
Guid deviceId )
inline

◆ PTZMoveAbsolute()

void RecorderCommandService.PTZMoveAbsolute ( string token,
Guid deviceId,
PTZArgs ptzArgs )
inline

Request device to move to specified absolute PTZ position.
PTZArgs details:

  • 'movement' : direction names 'pan', 'tilt', 'zoom'
  • 'value' : Specifies direction for each movement. Values between -1..1 for pan and tilt, and 0..1 for zoom
  • 'speed' : Specifies speed for the direction. Values between 0..1
  • 'automatic' : .

    Only one movement can be sent in each command - however 'pan' and 'tilt' can be sent together.
Parameters
tokenSecurity token
deviceIdThe Guid for the camera
ptzArgsAbsolute PTZ position

The various PTZ commands may return an ErrorNumber and possibly a SubErrorNumber in the SOAP response in case the request fails.
The ErrorNumber and SubErrorNumber are returned in the SOAP fault details as two XML elements.
Error number 40295 indicates a PTZ-related error. For this error number the following sub error numbers are possible:

Sub error number Description
1 Occurs when device is not configured/loaded on the recording server.
2 Occurs when the device is not started or connection broken.
10 Occurs when the device does not support PTZ.
11 Occurs when the device does not support presets.
20 Occurs when the PTZ request is rejected because the PTZ request has lower priority than the current active ptz session priority.
21 Occurs when the request is rejected because too many requests for the device.
30 Occurs if trying to execute a PTZ request without having an active session.
31 Occurs if the session executing the request is not the currently active session.
32 Occurs when trying to start a PTZ session that is already started.
33 Occurs when trying to pause a PTZ session that is not running (paused or stopped).
40 Occurs when trying to pause a patrolling when there is no active patrolling session.
41 Occurs when trying to resume patrolling for session that is not paused.
50 Occurs when trying to start patrolling with a patrolling profile that doesn't exist.


As a example on the SOAP communication see the following SOAP request and response for the PTZMoveRelative command:
SOAP request:

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<soap:Body>
<PTZMoveRelative xmlns="http://videoos.net/2/XProtectCSRecorderCommand">
<token>TOKEN#54d23aa1-59cd-4555-8de3-c57de040625a##</token>
<deviceId>b43d5369-6a4e-4364-ba2d-20b3a5814146</deviceId>
<ptzArgs>
<movement>
<name>pan</name>
<value>1</value>
</movement>
<speed>
<name>pan</name>
<value>1</value>
</speed>
<Normalized>false</Normalized>
</ptzArgs>
</soap:Body>
</soap:Envelope>
void PTZMoveRelative(string token, Guid deviceId, PTZArgs ptzArgs)
The 'PTZMoveRelative' command move the specific camera in the given direction - one time....
Definition RecorderCommandService.cs:411

SOAP response:

<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>
<soap:Fault>
<faultcode>soap:Server</faultcode>
<faultstring>Request rejected, request priority (100) lower than current priority (1000).</faultstring>
<detail>
<ErrorNumber>40295</ErrorNumber>
<SubErrorNumber>20</SubErrorNumber>
</detail>
</soap:Fault>
</soap:Body>
</soap:Envelope>

◆ PTZMoveHome()

void RecorderCommandService.PTZMoveHome ( string token,
Guid deviceId )
inline

Request device to move to home position (as defined by the device itself)

Parameters
tokenSecurity token
deviceIdDevice ID

For error handling see example for PTZMoveAbsolute.

◆ PTZMoveRelative()

void RecorderCommandService.PTZMoveRelative ( string token,
Guid deviceId,
PTZArgs ptzArgs )
inline

The 'PTZMoveRelative' command move the specific camera in the given direction - one time.
PTZArgs details:

  • 'movement' : direction names 'pan', 'tilt', 'zoom', 'iris', 'gain', 'shutter', 'brightness'
  • 'value' : Specifies direction(s) for each movement. -1; 0; 1
  • 'speed' : (ignored).
  • 'automatic' : (ignored).

    Only one movement can be sent in each command - however 'pan' and 'tilt' can be sent together.

movement values:
'pan' : -1=left ; 1=right;
'tilt' : -1=up ; 1=down
'zoom' : -1=out ; 1=in
'iris' : -1=down ; 1=up; 0=reset
'gain' : -1=down ; 1=up; 0=reset
'shutter' : -1=down ; 1=up; 0=reset
'brightness' : -1=down ; 1=up; 0=reset

Parameters
tokenSecurity token
deviceIdDevice ID
ptzArgsRelative PTZ coordinates

For error handling see example for PTZMoveAbsolute.

◆ PTZMoveStart()

void RecorderCommandService.PTZMoveStart ( string token,
Guid deviceId,
PTZArgs ptzArgs )
inline

Start move with given speed parameters. Movement will continue until a PTZMoveStop or some other command is received. PTZArgs details:

  • 'movement' : direction names 'pan', 'tilt', 'zoom', 'focus'
  • 'value' : Specifies direction(s) for each movement ('pan', 'tilt', 'zoom'). -1; 0; 1
  • 'speed' : Specifies speed(s) for each movement ('pan', 'tilt', 'zoom'). A value between 0 and 1.
  • 'automatic' : (Optional) A boolean indicating whether automatic is activated for the movement (only supported for focus).

movement; value; speed:
'pan'; 1, 0.5 : move right; half speed
'pan'; -1, 1 : move left; full speed
'pan'; 0, 0 : stop pan
'tilt'; 1, 0.5 : move down; half speed
'tilt'; -1, 1 : move up; full speed
'tilt'; 0, 0 : stop tilt
pan and tilt direction+speed is calculated together by driver if both are defined.
'zoom'; 1, 0.5 : zoom out; half speed
'zoom'; -1, 1 : zoom in; full speed
'zoom'; 0, 0 : stop zoom

Parameters
tokenSecurity token
deviceIdDevice ID
ptzArgsPTZ parameters, speed is read from "speed" collection and direction is read from sign on parameters in "movement" collection.

For error handling see example for PTZMoveAbsolute.

◆ PTZMoveStop()

void RecorderCommandService.PTZMoveStop ( string token,
Guid deviceId )
inline

Request device to stop a current move operation (started with PTZMoveStart)

Parameters
tokenSecurity token
deviceIdDevice ID

For error handling see example for PTZMoveAbsolute.

◆ PTZRectangle()

void RecorderCommandService.PTZRectangle ( string token,
Guid deviceId,
double refWidth,
double refHeight,
double left,
double top,
double bottom,
double right )
inline

Request PTZ device to show a specified rectangle.

Parameters
tokenSecurity token
deviceIdDevice ID
refWidthReference width
refHeightReference height
leftHorizontal position of left edge of rectangle relative to refWidth
topVertical position of top edge of rectangle relative to refHeight
bottomVertical position of bottom edge of rectangle relative to refHeight
rightHorizontal position of right edge of rectangle relative to refWidth

For error handling see example for PTZMoveAbsolute.

◆ PTZReleaseSession()

void RecorderCommandService.PTZReleaseSession ( string token,
Guid deviceId )
inline

◆ PTZReserveSession()

void RecorderCommandService.PTZReserveSession ( string token,
Guid deviceId )
inline

◆ SendDriverCommand()

void RecorderCommandService.SendDriverCommand ( string token,
Guid deviceId,
string command )
inline

◆ SequencesGet()

SequenceEntry[] RecorderCommandService.SequencesGet ( string token,
Guid deviceId,
Guid sequenceType,
DateTime minTime,
DateTime maxTime,
int maxCount )
inline

Get chronological list of sequences for a given sequence type with specified minimum time, maximum time and maximum count. Sequences are processed onwards from minTime and are sorted by TimeBegin.

Parameters
tokenSecurity token
deviceIdDevice ID
sequenceTypeThe requested sequence type.
The following types are currently supported:

RecordingSequence : {F9C62604-D0C5-4050-AE25-72DE51639B14}
MotionSequence : {53CB5E33-2183-44bd-9491-8364D2457480}
RecordingWithTriggerSequence : {0601D294-B7E5-4d93-9614-9658561AD5E4}
minTimeMinimum time as UTC
maxTimeMaximum time as UTC
maxCount
Returns

◆ SequencesGetAround()

SequenceEntry[] RecorderCommandService.SequencesGetAround ( string token,
Guid deviceId,
Guid sequenceType,
DateTime centerTime,
int maxCountBefore,
int maxCountAfter )
inline

Get chronological list of sequences for a given sequence type with specified center time, maximum count before center time and maximum count after center time. A sequence with TimeBegin equal to centertime will increase "after" count.

Parameters
tokenSecurity token
deviceIdDevice ID
sequenceTypeThe requested sequence type.
The following types are currently supported:

RecordingSequence : {F9C62604-D0C5-4050-AE25-72DE51639B14}
MotionSequence : {53CB5E33-2183-44bd-9491-8364D2457480}
RecordingWithTriggerSequence : {0601D294-B7E5-4d93-9614-9658561AD5E4}
centerTimeCentertime as UTC
maxCountBefore
maxCountAfter
Returns

◆ SequencesGetAroundWithSpan()

SequenceEntry[] RecorderCommandService.SequencesGetAroundWithSpan ( string token,
Guid deviceId,
Guid sequenceType,
DateTime centerTime,
TimeDuration maxTimeBefore,
int maxCountBefore,
TimeDuration maxTimeAfter,
int maxCountAfter )
inline

Get chronological list of sequences for a given sequence type with specified center time, maximum count before center time and maximum count after center time. Furthermore, search is limited before and after centertime by maximum timespans.

Parameters
tokenSecurity token
deviceIdDevice ID
sequenceTypeThe requested sequence type. The following types are currently supported: RecordingSequence : {F9C62604-D0C5-4050-AE25-72DE51639B14}
MotionSequence : {53CB5E33-2183-44bd-9491-8364D2457480}
RecordingWithTriggerSequence : {0601D294-B7E5-4d93-9614-9658561AD5E4}
centerTimeCentertime as UTC
maxTimeBefore
maxCountBefore
maxTimeAfter
maxCountAfter
Returns

◆ SequencesGetTypes()

SequenceType[] RecorderCommandService.SequencesGetTypes ( string token,
Guid deviceId )
inline

Get list of available sequence types for a given device.

Parameters
tokenSecurity token
deviceIdDevice ID
Returns
A list of supported sequence types, currently:
Name : Id

RecordingSequence : {F9C62604-D0C5-4050-AE25-72DE51639B14}
MotionSequence : {53CB5E33-2183-44bd-9491-8364D2457480}
RecordingWithTriggerSequence : {0601D294-B7E5-4d93-9614-9658561AD5E4}

◆ SmartSearchCancel()

void RecorderCommandService.SmartSearchCancel ( string token,
Guid smartSearchId )
inline

Cancels a specified smart search operation.

Parameters
tokenSecurity token
smartSearchIdSmart search operation ID

◆ SmartSearchGetResult()

SmartSearchResult RecorderCommandService.SmartSearchGetResult ( string token,
Guid smartSearchId,
bool continueSearch )
inline

Return the result a specified smart search operation.

Parameters
tokenSecurity token
smartSearchIdSmart search operation ID
continueSearchIndicates whether the search shall continue or not.
Returns
The smart search result

◆ SmartSearchGetStatus()

SmartSearchStatus RecorderCommandService.SmartSearchGetStatus ( string token,
Guid smartSearchId )
inline

Return the status of a specified smart search operation.

Parameters
tokenSecurity token
smartSearchIdSmart search operation ID
Returns
The smart search status

◆ SmartSearchStart()

Guid RecorderCommandService.SmartSearchStart ( string token,
Guid deviceId,
DateTime searchBeginTime,
DateTime searchEndTime,
int sensitivity,
TimeDuration searchInterval,
ImageMask searchMask,
bool ignoreInitialMotion,
System.Drawing.Size resultMotionMaskSize )
inline

Starts a smart serch operation on the server.

Parameters
tokenSecurity token
deviceIdDevice ID
searchBeginTimeThe begin time of the smart search.
searchEndTimeThe end time of the smart search.
sensitivitySearch sensitivity value between 0 and 100 where 100 is the highest sensitivity.
searchIntervalSearch interval specifying the interval of the images that are searched.
searchMaskMask specifying witch parts of the image to perform the smart search on.
ignoreInitialMotionIf true initial motion is ignored
resultMotionMaskSizeThe requested size of the motion mask returned by the SmartSearchGetResult method.
Returns

A guid identifying the smart search operation. Used when polling the recorder for status and results.

◆ StartManualRecording()

ManualRecordingResult[] RecorderCommandService.StartManualRecording ( string token,
Guid[] deviceIds )
inline

This method requests a start of manual recording on a device. The start manual recording request will start recording on the device if recording has not already been started because of other rules: A service channel event is sent when the evaluation of start manual recording has been made. If manual recording is already active, the command is simply ignore but the request is still successful.

Parameters
tokenSecurity token
deviceIdsDevice ID

◆ StartRecording()

bool RecorderCommandService.StartRecording ( string token,
Guid deviceId,
long recordingTimeMicroSeconds )
inline

This method is only supported by E-Code family. For manual recording use StartManualRecording.

Parameters
tokenSecurity token
deviceIdDevice ID
recordingTimeMicroSeconds

◆ StopManualRecording()

ManualRecordingResult[] RecorderCommandService.StopManualRecording ( string token,
Guid[] deviceIds )
inline

This method requests a stop of manual recording on a device. Please note that stopping manual recording does not necessary mean that the device stops recording. The device might still record because of other recording rules, just not because of manual recording. A service channel event is sent when the evaluation of stop manual recording has been made. If manual recording is already stopped, the command is simply ignore but the request is still successful.

Parameters
tokenSecurity token
deviceIdsDevice ID

◆ TimeLineInformationGet()

TimeLineInformationData[] RecorderCommandService.TimeLineInformationGet ( string token,
Guid deviceId,
Guid[] timeLineInformationTypes,
DateTime timeLineInformationBeginTime,
TimeDuration timeLineInformationInterval,
int timeLineInformationCount )
inline

Gets specified timeline information.

Parameters
tokenSecurity token
deviceIdDevice ID
timeLineInformationTypesArray of guids specifying the requested time line information types.
The following types are currently supported:
RecordedDataAvailable : {78289503-CBF4-43be-9DC3-9F34A8B60E6D}
ActivitiesDetected (motion) : {F445CE14-0038-4302-994E-39D99E4C0733}
timeLineInformationBeginTimeThe requested begin time of the time line information
timeLineInformationIntervalThe requested interval between each discrete time line information value
timeLineInformationCountThe requested number of time line information values
Returns
An array of TimeLineInformationData classes that each contains the data of the requested time line information types. It is not guarantied that the begin time, interval and count of the returned information matches the requested values, so the caller is required to use the returned values when examining the data. If data are available for the requested interval the interval returned must never be less then the requested interval. The returned interval must always reflect a persisted interval where data are fixed and will not be changed at a later time.