How to forward PTZ instructions in C#
This article show you how to forward the Pan-Tilt-Zoom instructions to the Onvif camera through the server in C#.
What is PTZ?
An IP camera with pan-tilt-zoom (PTZ) functionalities is capable of directional and zoom controlling remotely. These systems can be remotely controlled by automated systems as well as users. The PTZ controls are generally sold separately without the cameras. To fully understand this article, you might have to study the How to implement PTZ IP camera motion control in C# chapter.
How to send PTZ instructions through the server?
An avarage camera lets one or two clients to stream at the same time but this problem is easy to solve with Ozeki Camera SDK. With this you can create a server application which handles your clients. By using this, lots of clients will be able to connect to the server and you can make it possible to stream to multiple users at the same time. Usually, more than one people want to use the same camera, so it is possible to the camera channel fills quickly. Using a server application these limitations will be gone.
If the server is connected to the camera which is able to PTZ, then the client sends the PTZ command and the server can move the camera according to it (Figure 1). Multiple clients can control the same camera at the same time so it is recommended to install regulations of PTZ-ing to your server.
Below you can find the answers for the most frequently asked questions related to this topic:
I have not managed to build the solution. How to solve it?
- Please set the Target framework property of the project to .NET 4.0.
- You should add the OzekiSDK.dll to the references of the solution.
- Please import the missing classes.
Why is the camera moving, when I am not using it?
It is possible that someone else is also using the camera.
Why cannot I turn the camera in bigger angle than the current?
Because all camera have a limit in rotation.
- How to turn your USB camera into an Onvif IP webcam in C#
- How to turn your old RTSP ip camera into an Onvif IP webcam in C#
- Send video to Iphone Android mobile in C#
- C# stream video to multiple locations simultaneously
- How to make your software discoverable by other applications in C#
- Connect to RTSP camera stream, broadcasted by VLC media player
- How to find not Onvif cameras on the network
- How to compress h.263 and h.264 codec in C#