How to Determine Camera's PTZ Type(Absolute or Continuous or Relative) using MIP SDK

We have a 32bit WPF application. We want to make a “MileStone Component Integration” using MIP SDK. Our goal is to communicate with MileStone VMS and determine the PTZ Type(Absolute or Continuous or Relative) of a particular camera. Following example will describe the scenario in more detail:

Say we have six cameras(C1 to C6), among them four(C1 to C4) are PTZ enabled. Now suppose: C1 supports Absolute PTZ only, C2 supports Continuous PTZ only, C3 supports Relative PTZ only, and C4 supports both Absolute and Continuous PTZ. Programmatically how we can get this information from MileStone.

We have check the VideoOS.Platform.Item class and found that each item(in our case a Camera) has a read-only key-value pair property(public virtual Dictionary<string, string> Properties { get; }).

We have the MileStone’s sample C# application(PTZandPresets) to check PTZ operations and we have checked the key-value properties for one of our PTZ camera and the values are:

PTZ : Yes

PTZCenter : Yes

PTZRectangle : No

PTZHome : Yes

PTZDiagonal : Yes

pan : Relative

tilt : Relative

zoom : Relative

Ipix : No

PanoramicLens : No

ShortCut :

EdgeSupported : No

Channel : 0

In the above key-value collection, there are three properties(in bold font): “pan”, “tilt” and “zoom”. Does these properties implies that the camera supports only Relative PTZ. If yes, what will be the value for Absolute or Continuous or both Absolute and Continuous(or any other combination). I was wondering if there is any MIP SDK documentation regarding this or any C# code to find out the camera PTZ type.

The information you get back is all the information available.

If the device is actually a device that could be configured to be either relative or absolute the information is not known by the MIP configuration. Unfortunately you cannot get more information using any method in the MIP SDK.

Thanks for the information Bo. Let me describe my requirement in a different way.

In the PTZandPresets application (MileStone sample code found from MIP SDK installation), there is a section “Move continuously” where an user can specify the Pan, Tilt and Zoom value (and corresponding speed value) and press the “Start Move” button. I have attached an image file with this post.

Now I have two PTZ enabled cameras, one of which does not support Continuous Move and the other one support. I would like to show or hide the “Move continuously” section depending on camera selection by the user. I was wondering how I can achieve this functionality by programming.

Before I try to answer I would like to get a better understanding. Can you please tell me about the cameras?

The camera that fails to move continuously: What is the make, model and firmware version? What driver does it use in XProtect?

The camera that moves correctly continuously: What is the make, model and firmware version? What driver does it use in XProtect?

You might have more than one example of each of the two categories, I have an idea seeing the examples might be an eye opener for me.

The scenario(two cameras where one supports Continuous PTZ and other is not), that I described in my last post, is just an example to demonstrate my requirement. In actual scenario, my client provides me two cameras for development and testing purpose. One is PTZ enabled and other is not. Now when I applied the Continuous movement code (found from Milestone’s sample application PTZandPresets) on my PTZ enabled camera, nothing was happening, that is I did not get any visual effect. But I do get visual effects when I perform normal(Absolute or Relative) PTZ operations. So it seems to me that the camera does not support Continuous movement.

Now in real life, there may be multiple cameras where some of the cameras support Continuous PTZ and some not. My requirement is to show or hide the “Move continuously” section depending on the camera selection made by the user.

Camera information(that you asked for in your last post) are as follows:

What is the make and model of the camera?

OE-C6123-W2

What is the currently installed firmware version on that camera?

pc20180425NSQ

I do not find OE-C6123-W2 in the Milestone list of supported hardware. What driver does it use in XProtect? (I think getting concrete on the driver and the looking into the driver capabilities can get me closer to being able to answer.)

I would like to share complete camera information again. I have two cameras: one is PTZ enabled and other is not. Camera information are given below:

PTZ enabled camera:

Model: OpenEye OE-C8213

Version: pc20190118RS

Driver: ONVIF Conformant Device

Non PTZ camera

Model: OpenEye OE-C6123-W2

Version: pc20180425NSQ

Driver: ONVIF Conformant Device

After some deeper technical discussions with driver developer colleagues here at Milestone I think I can answer. Sorry to have kept you waiting.

The Milestone camera driver does not check if the device supports any of the mentioned capabilities.

The driver receive a command and try to execute it, if it fails it logs an error, otherwise it sends the command to the device.

As far as the driver code goes some functions are designed to use Absolute movement (PTZSetAbsoluteDoubles), others Relative (PTZCenterClick) and another Continuous (PTZMoveXYZ). This is why the driver does not check if the device supports the capability.

For an ONVIF device it is possible to check the PTZ configurations (as described in the ONVIF PTZ specification) provided by the device, but this is as seen above not something the Milestone Onvif driver does and it is therefore not possible to extract this information from the VMS using the MIP SDK (or in any other manner).