The DummyPointingDevice class is a pseudo-device class. It is used for testing and debugging purposes.
More...
#include <DummyPointingDevice.h>
|
| | DummyPointingDevice (URI uri) |
| | The constructor. More...
|
| |
| double | getResolution (double *=0) const |
| | Resolution of the mouse in CPI (counts per inch). More...
|
| |
| double | getUpdateFrequency (double *=0) const |
| | Update frequency of the mouse in Hz. More...
|
| |
| URI | getURI (bool expanded=false, bool crossplatform=true) const |
| | Constructs the URI according to the parameters of the device. More...
|
| |
|
void | setPointingCallback (PointingCallback, void *) |
| | The callback function will never be executed. The purpose of this class is to return specified resolution and update frequency when queried.
|
| |
| virtual bool | isActive (void) const |
| | Indicates whether the current device is active. More...
|
| |
| virtual int | getVendorID (void) const |
| | Vendor identifier number. More...
|
| |
| virtual std::string | getVendor (void) const |
| | Readable vendor name. More...
|
| |
| virtual int | getProductID (void) const |
| | Product identifier number. More...
|
| |
| virtual std::string | getProduct (void) const |
| | Readable product name. More...
|
| |
|
virtual void | setDebugLevel (int) |
| | Sets the level of information for debugging purposes (default = 0).
|
| |
|
virtual void | debug (std::ostream &) const |
| | Outputs the debug information to the given output stream.
|
| |
| int | mm2counts (double millimeters) const |
| |
| double | counts2mm (int counts) const |
| |
| int | in2counts (double inches) const |
| |
| double | counts2in (int counts) const |
| |
|
| enum | { BUTTON_1 =1,
BUTTON_2 =2,
BUTTON_3 =4
} |
| |
| typedef void(* | PointingCallback )(void *context, TimeStamp::inttime timestamp, int dx, int dy, int buttons) |
| |
| static void | idle (int milliseconds) |
| | The function is used to sleep the current thread. More...
|
| |
| static PointingDevice * | create (const char *device_uri=0) |
| | This static function is used to instantiate a platform-specific object of the class. More...
|
| |
| static PointingDevice * | create (std::string device_uri) |
| | This static function is used to instantiate a platform-specific object of the class. More...
|
| |
| void | registerTimestamp (TimeStamp::inttime timestamp) |
| | registerTimestamp Registers the current timestamp to calculate frequency of the device More...
|
| |
| double | estimatedUpdateFrequency () const |
| | estimatedUpdateFrequency Estimates the frequency depending on the input timestamps More...
|
| |
|
unsigned long | buckets [BUCKETS_SIZE] |
| |
|
TimeStamp::inttime | lastTime |
| |
|
static const int | BUCKETS_SIZE = 5 |
| |
The DummyPointingDevice class is a pseudo-device class. It is used for testing and debugging purposes.
It can be instantiated with PointingDevice::create function with the following URI: dummy:?cpi=800&hz=125
| pointing::DummyPointingDevice::DummyPointingDevice |
( |
URI |
uri | ) |
|
The constructor.
- Parameters
-
| uri | Instantiates the device according to the given URI. |
| double pointing::DummyPointingDevice::getResolution |
( |
double * |
defval = 0 | ) |
const |
|
inlinevirtual |
Resolution of the mouse in CPI (counts per inch).
- Parameters
-
| defval | is input variable to define explicitly the resolution. |
- Returns
- Resolution in CPI (if not available 400 cpi).
Implements pointing::PointingDevice.
| double pointing::DummyPointingDevice::getUpdateFrequency |
( |
double * |
defval = 0 | ) |
const |
|
inlinevirtual |
Update frequency of the mouse in Hz.
- Parameters
-
| defval | is input variable to define explicitly the update frequency. |
- Returns
- Update frequency in Hz (if not available 125 Hz).
Implements pointing::PointingDevice.
| URI pointing::DummyPointingDevice::getURI |
( |
bool |
expanded = false, |
|
|
bool |
crossplatform = true |
|
) |
| const |
|
virtual |
Constructs the URI according to the parameters of the device.
- Parameters
-
| expanded | specifies if additional parameters must be displayed. |
| crossplatform | defines whether the URI should be crossplatform. if True vendorId and productId are included in the URI |
- Returns
- The corresponding URI of the device.
Implements pointing::PointingDevice.
The documentation for this class was generated from the following files: