Next: 2.17 SonarProxy
Up: 2. Class Reference
Previous: 2.15 PowerProxy
Contents
Subsections
The PtzProxy class is used to control a ptz device. The state of the camera can be read from the pan, tilt, zoom attributes and changed using the SetCam() method.
double pan, tilt, zoom;
Pan, tilt, and field of view values (all radians).
double panspeed, tiltspeed;
Pan and tilt speeds (rad/sec)
PtzProxy(PlayerClient* pc, unsigned short index,
unsigned char access='c')
Constructor. Leave the access field empty to start unconnected.
int SetCam(double pan, double tilt, double zoom)
Change the camera state. Specify the new pan, tilt, and zoom values (all degrees). Returns: 0 if everything's ok, -1 otherwise.
int SetSpeed(double panspeed, double tiltspeed)
Specify new target velocities
int SendConfig(uint8_t *bytes, size_t len, uint8_t *reply = NULL,
size_t reply_len = 0)
Send a camera-specific config
int SelectControlMode(uint8_t mode)
Select new control mode. Use either PLAYER_PTZ_POSITION_CONTROL or PLAYER_PTZ_VELOCITY_CONTROL.
void Print()
Print out current ptz state.
2004-05-31