Fawkes API  Fawkes Development Version
visca.h
1 
2 /***************************************************************************
3  * visca.h - Class for accessing visca cams
4  *
5  * Generated: Wed Jun 08 12:06:15 2005
6  * Copyright 2005-2007 Tim Niemueller [www.niemueller.de]
7  *
8  ****************************************************************************/
9 
10 /* This program is free software; you can redistribute it and/or modify
11  * it under the terms of the GNU General Public License as published by
12  * the Free Software Foundation; either version 2 of the License, or
13  * (at your option) any later version. A runtime exception applies to
14  * this software (see LICENSE.GPL_WRE file mentioned below for details).
15  *
16  * This program is distributed in the hope that it will be useful,
17  * but WITHOUT ANY WARRANTY; without even the implied warranty of
18  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19  * GNU Library General Public License for more details.
20  *
21  * Read the full text in the LICENSE.GPL_WRE file in the doc directory.
22  */
23 
24 #ifndef _FIREVISION_CONTROL_VISCA_H_
25 #define _FIREVISION_CONTROL_VISCA_H_
26 
27 #include <core/exception.h>
28 
29 #ifdef TIMETRACKER_VISCA
30 # warning Visca time tracker enabled
31 # include <utils/timetracker.h>
32 
33 # include <fstream>
34 #endif
35 
36 #include <cstddef>
37 
38 namespace firevision {
39 
41 {
42 public:
43  ViscaControlException(const char *msg);
44  ViscaControlException(const char *msg, const int _errno);
45 };
46 
48 {
49 public:
51 };
52 
54 {
55 public:
56  static const unsigned int VISCA_WHITEBLANCE_AUTO;
57  static const unsigned int VISCA_WHITEBALANCE_INDOOR;
58  static const unsigned int VISCA_WHITEBALANCE_OUTDOOR;
59  static const unsigned int VISCA_WHITEBALANCE_ONE_PUSH;
60  static const unsigned int VISCA_WHITEBALANCE_ATW;
61  static const unsigned int VISCA_WHITEBALANCE_MANUAL;
62 
63  ViscaControl(bool blocking = true);
64 
65  void open(const char *port);
66  void close();
67 
68  // basic communication
69  void set_address(unsigned int num_cameras);
70  void clear();
71 
72  // low level
73  void send();
74  void recv(unsigned int max_wait_ms = 10);
75  void recv_ack(unsigned int *socket = NULL);
76  void send_with_reply();
77  void send_nonblocking(unsigned int *socket = NULL);
78  void cancel_command(unsigned int socket);
79  bool data_available();
80  void process();
81 
82  // pan tilt stuff
83  void resetPanTilt();
84  /** Query for pan/tilt but do not wait until finished
85  * This will send an inquire to the camera that asks for pan/tilt values but
86  * it does not wait for the data! A later call to getPanTilt will then block and
87  * wait until the results arrive.
88  * Not that you can _not_ run another inquire (get*) method until this call has
89  * finished! You will get VISCA_E_INQRUNNING as error message.
90  */
91  void startGetPanTilt();
92  void setPanTilt(int pan, int tilt);
93  void getPanTilt(int *pan, int *tilt);
94  void setPanTiltLimit(int pan_left, int pan_right, int tilt_up, int tilt_down);
95  void resetPanTiltLimit();
96 
97  // zoom
98  void resetZoom();
99  void setZoom(unsigned int zoom);
100  void getZoom(unsigned int *zoom);
101  void setZoomSpeedTele(unsigned int speed);
102  void setZoomSpeedWide(unsigned int speed);
103  void setZoomDigitalEnabled(bool enabled);
104 
105  // effects, just to play with...
106  void resetEffect();
107  void applyEffect(unsigned char effect);
108  void applyEffectPastel();
109  void applyEffectNegArt();
110  void applyEffectSepia();
111  void applyEffectBnW();
112  void applyEffectSolarize();
113  void applyEffectMosaic();
114  void applyEffectSlim();
115  void applyEffectStretch();
116 
117  unsigned int getWhiteBalanceMode();
118 
119 private:
120  // possible running inquires
121  static const unsigned int VISCA_RUNINQ_NONE = 0;
122  static const unsigned int VISCA_RUNINQ_PANTILT = 1;
123 
124  // Cameras
125  static const unsigned char VISCA_BUS_0 = 0;
126  static const unsigned char VISCA_BUS_1 = 1;
127  static const unsigned char VISCA_BUS_2 = 2;
128  static const unsigned char VISCA_BUS_3 = 3;
129  static const unsigned char VISCA_BUS_4 = 4;
130  static const unsigned char VISCA_BUS_5 = 5;
131  static const unsigned char VISCA_BUS_6 = 6;
132  static const unsigned char VISCA_BUS_7 = 7;
133  static const unsigned char VISCA_BUS_BROADCAST = 8;
134 
135  // basic formatting
136  static const unsigned char VISCA_COMMAND = 0x01;
137  static const unsigned char VISCA_CANCEL = 0x20;
138  static const unsigned char VISCA_INQUIRY = 0x09;
139  static const unsigned char VISCA_TERMINATOR = 0xFF;
140 
141  // response types
142  static const unsigned char VISCA_RESPONSE_CLEAR = 0x40;
143  static const unsigned char VISCA_RESPONSE_ADDRESS = 0x30;
144  static const unsigned char VISCA_RESPONSE_ACK = 0x40;
145  static const unsigned char VISCA_RESPONSE_COMPLETED = 0x50;
146  static const unsigned char VISCA_RESPONSE_ERROR = 0x60;
147 
148  // errors
149  static const unsigned char VISCA_ERROR_LENGTH = 0x01;
150  static const unsigned char VISCA_ERROR_SYNTAX = 0x02;
151  static const unsigned char VISCA_ERROR_BUFFERFULL = 0x03;
152  static const unsigned char VISCA_ERROR_CANCELLED = 0x04;
153  static const unsigned char VISCA_ERROR_NOSOCKET = 0x05;
154  static const unsigned char VISCA_ERROR_NOTEXECABLE = 0x41;
155 
156  // categories
157  static const unsigned char VISCA_CATEGORY_INTERFACE = 0x00;
158  static const unsigned char VISCA_CATEGORY_CAMERA1 = 0x04;
159  static const unsigned char VISCA_CATEGORY_PAN_TILTER = 0x06;
160  static const unsigned char VISCA_CATEGORY_CAMERA2 = 0x07;
161 
162  static const unsigned char VISCA_POWER = 0x00;
163  static const unsigned char VISCA_DEVICE_INFO = 0x02;
164  static const unsigned char VISCA_KEYLOCK = 0x17;
165  static const unsigned char VISCA_ID = 0x22;
166  static const unsigned char VISCA_ZOOM = 0x07;
167  static const unsigned char VISCA_ZOOM_STOP = 0x00;
168  static const unsigned char VISCA_ZOOM_TELE = 0x02;
169  static const unsigned char VISCA_ZOOM_WIDE = 0x03;
170  static const unsigned char VISCA_ZOOM_TELE_SPEED = 0x20;
171  static const unsigned char VISCA_ZOOM_WIDE_SPEED = 0x30;
172  static const unsigned char VISCA_ZOOM_VALUE = 0x47;
173  static const unsigned char VISCA_ZOOM_FOCUS_VALUE = 0x47;
174  static const unsigned char VISCA_DZOOM = 0x06;
175  static const unsigned char VISCA_DZOOM_ON = 0x02;
176  static const unsigned char VISCA_DZOOM_OFF = 0x03;
177  static const unsigned char VISCA_FOCUS = 0x08;
178  static const unsigned char VISCA_FOCUS_STOP = 0x00;
179  static const unsigned char VISCA_FOCUS_FAR = 0x02;
180  static const unsigned char VISCA_FOCUS_NEAR = 0x03;
181  static const unsigned char VISCA_FOCUS_FAR_SPEED = 0x20;
182  static const unsigned char VISCA_FOCUS_NEAR_SPEED = 0x30;
183  static const unsigned char VISCA_FOCUS_VALUE = 0x48;
184  static const unsigned char VISCA_FOCUS_AUTO = 0x38;
185  static const unsigned char VISCA_FOCUS_AUTO_MAN = 0x10;
186  static const unsigned char VISCA_FOCUS_ONE_PUSH = 0x18;
187  static const unsigned char VISCA_FOCUS_ONE_PUSH_TRIG = 0x01;
188  static const unsigned char VISCA_FOCUS_ONE_PUSH_INF = 0x02;
189  static const unsigned char VISCA_FOCUS_AUTO_SENSE = 0x58;
190  static const unsigned char VISCA_FOCUS_AUTO_SENSE_HIGH = 0x02;
191  static const unsigned char VISCA_FOCUS_AUTO_SENSE_LOW = 0x03;
192  static const unsigned char VISCA_FOCUS_NEAR_LIMIT = 0x28;
193  static const unsigned char VISCA_WB = 0x35;
194  static const unsigned char VISCA_WB_AUTO = 0x00;
195  static const unsigned char VISCA_WB_INDOOR = 0x01;
196  static const unsigned char VISCA_WB_OUTDOOR = 0x02;
197  static const unsigned char VISCA_WB_ONE_PUSH = 0x03;
198  static const unsigned char VISCA_WB_ATW = 0x04;
199  static const unsigned char VISCA_WB_MANUAL = 0x05;
200  static const unsigned char VISCA_WB_ONE_PUSH_TRIG = 0x05;
201  static const unsigned char VISCA_RGAIN = 0x03;
202  static const unsigned char VISCA_RGAIN_VALUE = 0x43;
203  static const unsigned char VISCA_BGAIN = 0x04;
204  static const unsigned char VISCA_BGAIN_VALUE = 0x44;
205  static const unsigned char VISCA_AUTO_EXP = 0x39;
206  static const unsigned char VISCA_AUTO_EXP_FULL_AUTO = 0x00;
207  static const unsigned char VISCA_AUTO_EXP_MANUAL = 0x03;
208  static const unsigned char VISCA_AUTO_EXP_SHUTTER_PRIORITY = 0x0A;
209  static const unsigned char VISCA_AUTO_EXP_IRIS_PRIORITY = 0x0B;
210  static const unsigned char VISCA_AUTO_EXP_GAIN_PRIORITY = 0x0C;
211  static const unsigned char VISCA_AUTO_EXP_BRIGHT = 0x0D;
212  static const unsigned char VISCA_AUTO_EXP_SHUTTER_AUTO = 0x1A;
213  static const unsigned char VISCA_AUTO_EXP_IRIS_AUTO = 0x1B;
214  static const unsigned char VISCA_AUTO_EXP_GAIN_AUTO = 0x1C;
215  static const unsigned char VISCA_SLOW_SHUTTER = 0x5A;
216  static const unsigned char VISCA_SLOW_SHUTTER_AUTO = 0x02;
217  static const unsigned char VISCA_SLOW_SHUTTER_MANUAL = 0x03;
218  static const unsigned char VISCA_SHUTTER = 0x0A;
219  static const unsigned char VISCA_SHUTTER_VALUE = 0x4A;
220  static const unsigned char VISCA_IRIS = 0x0B;
221  static const unsigned char VISCA_IRIS_VALUE = 0x4B;
222  static const unsigned char VISCA_GAIN = 0x0C;
223  static const unsigned char VISCA_GAIN_VALUE = 0x4C;
224  static const unsigned char VISCA_BRIGHT = 0x0D;
225  static const unsigned char VISCA_BRIGHT_VALUE = 0x4D;
226  static const unsigned char VISCA_EXP_COMP = 0x0E;
227  static const unsigned char VISCA_EXP_COMP_POWER = 0x3E;
228  static const unsigned char VISCA_EXP_COMP_VALUE = 0x4E;
229  static const unsigned char VISCA_BACKLIGHT_COMP = 0x33;
230  static const unsigned char VISCA_APERTURE = 0x02;
231  static const unsigned char VISCA_APERTURE_VALUE = 0x42;
232  static const unsigned char VISCA_ZERO_LUX = 0x01;
233  static const unsigned char VISCA_IR_LED = 0x31;
234  static const unsigned char VISCA_WIDE_MODE = 0x60;
235  static const unsigned char VISCA_WIDE_MODE_OFF = 0x00;
236  static const unsigned char VISCA_WIDE_MODE_CINEMA = 0x01;
237  static const unsigned char VISCA_WIDE_MODE_16_9 = 0x02;
238  static const unsigned char VISCA_MIRROR = 0x61;
239  static const unsigned char VISCA_FREEZE = 0x62;
240  static const unsigned char VISCA_PICTURE_EFFECT = 0x63;
241  static const unsigned char VISCA_PICTURE_EFFECT_OFF = 0x00;
242  static const unsigned char VISCA_PICTURE_EFFECT_PASTEL = 0x01;
243  static const unsigned char VISCA_PICTURE_EFFECT_NEGATIVE = 0x02;
244  static const unsigned char VISCA_PICTURE_EFFECT_SEPIA = 0x03;
245  static const unsigned char VISCA_PICTURE_EFFECT_BW = 0x04;
246  static const unsigned char VISCA_PICTURE_EFFECT_SOLARIZE = 0x05;
247  static const unsigned char VISCA_PICTURE_EFFECT_MOSAIC = 0x06;
248  static const unsigned char VISCA_PICTURE_EFFECT_SLIM = 0x07;
249  static const unsigned char VISCA_PICTURE_EFFECT_STRETCH = 0x08;
250  static const unsigned char VISCA_DIGITAL_EFFECT = 0x64;
251  static const unsigned char VISCA_DIGITAL_EFFECT_OFF = 0x00;
252  static const unsigned char VISCA_DIGITAL_EFFECT_STILL = 0x01;
253  static const unsigned char VISCA_DIGITAL_EFFECT_FLASH = 0x02;
254  static const unsigned char VISCA_DIGITAL_EFFECT_LUMI = 0x03;
255  static const unsigned char VISCA_DIGITAL_EFFECT_TRAIL = 0x04;
256  static const unsigned char VISCA_DIGITAL_EFFECT_LEVEL = 0x65;
257  static const unsigned char VISCA_MEMORY = 0x3F;
258  static const unsigned char VISCA_MEMORY_RESET = 0x00;
259  static const unsigned char VISCA_MEMORY_SET = 0x01;
260  static const unsigned char VISCA_MEMORY_RECALL = 0x02;
261  static const unsigned char VISCA_DISPLAY = 0x15;
262  static const unsigned char VISCA_DISPLAY_TOGGLE = 0x10;
263  static const unsigned char VISCA_DATE_TIME_SET = 0x70;
264  static const unsigned char VISCA_DATE_DISPLAY = 0x71;
265  static const unsigned char VISCA_TIME_DISPLAY = 0x72;
266  static const unsigned char VISCA_TITLE_DISPLAY = 0x74;
267  static const unsigned char VISCA_TITLE_DISPLAY_CLEAR = 0x00;
268  static const unsigned char VISCA_TITLE_SET = 0x73;
269  static const unsigned char VISCA_TITLE_SET_PARAMS = 0x00;
270  static const unsigned char VISCA_TITLE_SET_PART1 = 0x01;
271  static const unsigned char VISCA_TITLE_SET_PART2 = 0x02;
272  static const unsigned char VISCA_IRRECEIVE = 0x08;
273  static const unsigned char VISCA_IRRECEIVE_ON = 0x02;
274  static const unsigned char VISCA_IRRECEIVE_OFF = 0x03;
275  static const unsigned char VISCA_IRRECEIVE_ONOFF = 0x10;
276  static const unsigned char VISCA_PT_DRIVE = 0x01;
277  static const unsigned char VISCA_PT_DRIVE_HORIZ_LEFT = 0x01;
278  static const unsigned char VISCA_PT_DRIVE_HORIZ_RIGHT = 0x02;
279  static const unsigned char VISCA_PT_DRIVE_HORIZ_STOP = 0x03;
280  static const unsigned char VISCA_PT_DRIVE_VERT_UP = 0x01;
281  static const unsigned char VISCA_PT_DRIVE_VERT_DOWN = 0x02;
282  static const unsigned char VISCA_PT_DRIVE_VERT_STOP = 0x03;
283  static const unsigned char VISCA_PT_ABSOLUTE_POSITION = 0x02;
284  static const unsigned char VISCA_PT_RELATIVE_POSITION = 0x03;
285  static const unsigned char VISCA_PT_HOME = 0x04;
286  static const unsigned char VISCA_PT_RESET = 0x05;
287  static const unsigned char VISCA_PT_LIMITSET = 0x07;
288  static const unsigned char VISCA_PT_LIMITSET_SET = 0x00;
289  static const unsigned char VISCA_PT_LIMITSET_CLEAR = 0x01;
290  static const unsigned char VISCA_PT_LIMITSET_SET_UR = 0x01;
291  static const unsigned char VISCA_PT_LIMITSET_SET_DL = 0x00;
292  static const unsigned char VISCA_PT_DATASCREEN = 0x06;
293  static const unsigned char VISCA_PT_DATASCREEN_ON = 0x02;
294  static const unsigned char VISCA_PT_DATASCREEN_OFF = 0x03;
295  static const unsigned char VISCA_PT_DATASCREEN_ONOFF = 0x10;
296  static const unsigned char VISCA_PT_VIDEOSYSTEM_INQ = 0x23;
297  static const unsigned char VISCA_PT_MODE_INQ = 0x10;
298  static const unsigned char VISCA_PT_MAXSPEED_INQ = 0x11;
299  static const unsigned char VISCA_PT_POSITION_INQ = 0x12;
300  static const unsigned char VISCA_PT_DATASCREEN_INQ = 0x06;
301  /*****************/
302  /* D30/D31 CODES */
303  /*****************/
304  static const unsigned char VISCA_WIDE_CON_LENS = 0x26;
305  static const unsigned char VISCA_WIDE_CON_LENS_SET = 0x00;
306 
307  static const unsigned char VISCA_AT_MODE = 0x01;
308  static const unsigned char VISCA_AT_ONOFF = 0x10;
309  static const unsigned char VISCA_AT_AE = 0x02;
310  static const unsigned char VISCA_AT_AUTOZOOM = 0x03;
311  static const unsigned char VISCA_ATMD_FRAMEDISPLAY = 0x04;
312  static const unsigned char VISCA_AT_FRAMEOFFSET = 0x05;
313  static const unsigned char VISCA_ATMD_STARTSTOP = 0x06;
314  static const unsigned char VISCA_AT_CHASE = 0x07;
315  static const unsigned char VISCA_AT_CHASE_NEXT = 0x10;
316 
317  static const unsigned char VISCA_MD_MODE = 0x08;
318  static const unsigned char VISCA_MD_ONOFF = 0x10;
319  static const unsigned char VISCA_MD_FRAME = 0x09;
320  static const unsigned char VISCA_MD_DETECT = 0x0A;
321 
322  static const unsigned char VISCA_MD_ADJUST = 0x00;
323  static const unsigned char VISCA_MD_ADJUST_YLEVEL = 0x0B;
324  static const unsigned char VISCA_MD_ADJUST_HUELEVEL = 0x0C;
325  static const unsigned char VISCA_MD_ADJUST_SIZE = 0x0D;
326  static const unsigned char VISCA_MD_ADJUST_DISPTIME = 0x0F;
327  static const unsigned char VISCA_MD_ADJUST_REFTIME = 0x0B;
328  static const unsigned char VISCA_MD_ADJUST_REFMODE = 0x10;
329 
330  static const unsigned char VISCA_AT_ENTRY = 0x15;
331  static const unsigned char VISCA_AT_LOSTINFO = 0x20;
332  static const unsigned char VISCA_MD_LOSTINFO = 0x21;
333  static const unsigned char VISCA_ATMD_LOSTINFO1 = 0x20;
334  static const unsigned char VISCA_ATMD_LOSTINFO2 = 0x07;
335 
336  static const unsigned char VISCA_MD_MEASURE_MODE_1 = 0x27;
337  static const unsigned char VISCA_MD_MEASURE_MODE_2 = 0x28;
338 
339  static const unsigned char VISCA_ATMD_MODE = 0x22;
340  static const unsigned char VISCA_AT_MODE_QUERY = 0x23;
341  static const unsigned char VISCA_MD_MODE_QUERY = 0x24;
342  static const unsigned char VISCA_MD_REFTIME_QUERY = 0x11;
343  static const unsigned char VISCA_AT_POSITION = 0x20;
344  static const unsigned char VISCA_MD_POSITION = 0x21;
345 
346  static const unsigned int VISCA_NONBLOCKING_PANTILT = 0;
347  static const unsigned int VISCA_NONBLOCKING_ZOOM = 1;
348  static const unsigned int VISCA_NONBLOCKING_NUM = 2;
349 
350  void recv_packet(unsigned int max_wait_ms = 10);
351  void handle_response();
352  void finish_nonblocking(unsigned int socket);
353 
354  int dev;
355  bool opened;
356 
357  unsigned int inquire;
358 
359  // Visca specific
360  unsigned char recipient;
361  unsigned char sender;
362 
363  unsigned char obuffer[16];
364  unsigned char ibuffer[1024];
365  int obuffer_length;
366  int ibuffer_length;
367 
368  unsigned int num_commands_running;
369  bool blocking;
370  bool nonblocking_running[2];
371  unsigned int nonblocking_sockets[2];
372 #ifdef TIMETRACKER_VISCA
373  fawkes::TimeTracker *tracker;
374  std::ofstream track_file;
375  unsigned int ttcls_pantilt_get_send;
376  unsigned int ttcls_pantilt_get_read;
377  unsigned int ttcls_pantilt_get_handle;
378  unsigned int ttcls_pantilt_get_interpret;
379 #endif
380 };
381 
382 } // end namespace firevision
383 
384 #endif
static const unsigned int VISCA_WHITEBALANCE_OUTDOOR
Outdoor white balance preset.
Definition: visca.h:58
bool data_available()
Check data availability.
Definition: visca.cpp:265
static const unsigned int VISCA_WHITEBALANCE_ATW
ATW white balance preset.
Definition: visca.h:60
void close()
Close port.
Definition: visca.cpp:183
void resetPanTiltLimit()
Reset pan/tilt limit.
Definition: visca.cpp:688
void applyEffectStretch()
Apply stretch effect.
Definition: visca.cpp:1046
void setPanTilt(int pan, int tilt)
Set pan tilt.
Definition: visca.cpp:502
static const unsigned int VISCA_WHITEBALANCE_ONE_PUSH
One push white balance preset.
Definition: visca.h:59
void applyEffectMosaic()
Apply mosaic effect.
Definition: visca.cpp:1022
void send_with_reply()
Send and wait for reply, blocking.
Definition: visca.cpp:356
ViscaControlException(const char *msg)
Constructor.
Definition: visca.cpp:43
void set_address(unsigned int num_cameras)
Set addresses of cameras.
Definition: visca.cpp:195
Visca inquire running exception.
Definition: visca.h:47
ViscaControl(bool blocking=true)
Constructor.
Definition: visca.cpp:87
void applyEffectPastel()
Apply pastel effect.
Definition: visca.cpp:962
int _errno
Error number, should be used if the error was caused by a method that supplies errno.
Definition: exception.h:113
void applyEffectSolarize()
Apply solarize effect.
Definition: visca.cpp:1010
void getZoom(unsigned int *zoom)
Get zoom.
Definition: visca.cpp:874
unsigned int getWhiteBalanceMode()
Get white balance mode.
Definition: visca.cpp:1060
void applyEffectSlim()
Apply slim effect.
Definition: visca.cpp:1034
void send()
Send outbound queue.
Definition: visca.cpp:237
Visca control protocol implementation over a serial line.
Definition: visca.h:53
void resetZoom()
Reset zoom.
Definition: visca.cpp:785
void setPanTiltLimit(int pan_left, int pan_right, int tilt_up, int tilt_down)
Set pan tilt limit.
Definition: visca.cpp:724
void startGetPanTilt()
Query for pan/tilt but do not wait until finished This will send an inquire to the camera that asks f...
Definition: visca.cpp:556
void setZoomSpeedTele(unsigned int speed)
Set zoom speed in tele.
Definition: visca.cpp:805
void resetEffect()
Reset effects.
Definition: visca.cpp:950
Base class for exceptions in Fawkes.
Definition: exception.h:35
void setZoomSpeedWide(unsigned int speed)
Set zoom speed in wide angle.
Definition: visca.cpp:827
static const unsigned int VISCA_WHITEBALANCE_INDOOR
Indoor white balance preset.
Definition: visca.h:57
void recv_ack(unsigned int *socket=NULL)
Receive ACK packet.
Definition: visca.cpp:310
void open(const char *port)
Open serial port.
Definition: visca.cpp:103
Time tracking utility.
Definition: tracker.h:36
void resetPanTilt()
Reset pan/tilt.
Definition: visca.cpp:768
void applyEffectBnW()
Apply B/W effect.
Definition: visca.cpp:998
void setZoomDigitalEnabled(bool enabled)
Enable or disable digital zoome.
Definition: visca.cpp:908
void process()
Process incoming data.
Definition: visca.cpp:482
void setZoom(unsigned int zoom)
Set zoom.
Definition: visca.cpp:849
void recv(unsigned int max_wait_ms=10)
Receive data.
Definition: visca.cpp:276
void applyEffectSepia()
Apply sepia effect.
Definition: visca.cpp:986
void clear()
Clear.
Definition: visca.cpp:216
void getPanTilt(int *pan, int *tilt)
Get pan and tilt values.
Definition: visca.cpp:584
void cancel_command(unsigned int socket)
Cancel a running command.
Definition: visca.cpp:458
void send_nonblocking(unsigned int *socket=NULL)
Send non-blocking.
Definition: visca.cpp:342
static const unsigned int VISCA_WHITEBLANCE_AUTO
Automatic white balance.
Definition: visca.h:56
static const unsigned int VISCA_WHITEBALANCE_MANUAL
Manual white balance.
Definition: visca.h:61
void applyEffect(unsigned char effect)
Apply effect.
Definition: visca.cpp:932
void applyEffectNegArt()
Apply negative art effect.
Definition: visca.cpp:974