SoQtPowerMate Class Reference

Griffin PowerMate device driver for Open Inventor. More...

#include <SoQtPowerMate.h>

List of all members.

Public Types

enum  Mask { MOTION = 0x01, PRESS = 0x02, RELEASE = 0x04, ALL = 0x07 }
 Event mask values. More...

Public Member Functions

 SoQtPowerMate (Mask mask=SoQtPowerMate::ALL)
 Constructor.
 ~SoQtPowerMate ()
 Destructor.
virtual const SoEvent * translateEvent (QEvent *event)
 This converts a window system event into an SoEvent.
virtual void enable (QWidget *w, SoQtEventHandler *f, void *data)
 These functions will enable/disable this device for the passed widget.
virtual void disable (QWidget *w, SoQtEventHandler *f, void *data)
void setMotionScaleFactor (float f)
 Scale the effect of motion interactions.
float getMotionScaleFactor () const

Static Public Member Functions

static SbBool exists ()
 Return whether or not the Griffin PowerMate device exists for use.
static void initClass ()


Detailed Description

Griffin PowerMate device driver for Open Inventor.

The driver supports the Griffin Powermate device. On Mac OS X no additional driver is required. In fact, the Griffin driver must not be installed on Mac OS X.

The motion is translated to a SoPowerMateMotionEvent. The button state of the device gets translated into a SoPowerMateButtonEvent.

Author:
Felix Ritter
Date:
2007

Definition at line 42 of file SoQtPowerMate.h.


Member Enumeration Documentation

Event mask values.

Bitwise OR these to specify whichEvents this device should queue.

Enumerator:
MOTION  PowerMate knob motion.
PRESS  PowerMate button press.
RELEASE  PowerMate button release.
ALL  All PowerMate events.

Definition at line 52 of file SoQtPowerMate.h.


Constructor & Destructor Documentation

SoQtPowerMate::SoQtPowerMate ( Mask  mask = SoQtPowerMate::ALL  ) 

Constructor.

SoQtPowerMate::~SoQtPowerMate (  ) 

Destructor.


Member Function Documentation

virtual void SoQtPowerMate::disable ( QWidget *  w,
SoQtEventHandler *  f,
void *  data 
) [virtual]

virtual void SoQtPowerMate::enable ( QWidget *  w,
SoQtEventHandler *  f,
void *  data 
) [virtual]

These functions will enable/disable this device for the passed widget.

The callback function f will be invoked when events occur in w. data is the clientData which will be passed.

static SbBool SoQtPowerMate::exists (  )  [static]

Return whether or not the Griffin PowerMate device exists for use.

float SoQtPowerMate::getMotionScaleFactor (  )  const [inline]

Definition at line 89 of file SoQtPowerMate.h.

static void SoQtPowerMate::initClass (  )  [static]

void SoQtPowerMate::setMotionScaleFactor ( float  f  )  [inline]

Scale the effect of motion interactions.

The PowerMate reports knob motion as integer. This value must be scaled to be useful. These methods allow the scale value to be set. Default value is 1.

Definition at line 88 of file SoQtPowerMate.h.

virtual const SoEvent* SoQtPowerMate::translateEvent ( QEvent *  event  )  [virtual]

This converts a window system event into an SoEvent.

The function returns NULL if the event is not from this device.


The documentation for this class was generated from the following file:

Generated on Sat Sep 3 18:39:32 2011 for MeVisLab Toolbox Reference by  doxygen 1.5.8