Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Namespace Members | Class Members | File Members | Related Pages

# osgProducer::EventAdapter Class Reference

Class for adapting Producer events so that they can be used as input to osgGA::CameraManipulators. More...

Inheritance diagram for osgProducer::EventAdapter:

[legend]
List of all members.

## Public Member Functions
| EventAdapter ()
virtual | ~EventAdapter ()
virtual EventType | getEventType () const
| Get the EventType of the GUI event.
void | setKey (int key)
virtual int | getKey () const
| key pressed, return -1 if inappropriate for this event.
virtual int | getButton () const
| button pressed/released, return -1 if inappropriate for this event.
virtual float | getXmin () const
| window minimum x.
virtual float | getXmax () const
| window maximum x.
virtual float | getYmin () const
| window minimum y.
virtual float | getYmax () const
| window maximum y.
void | setX (float x)
virtual float | getX () const
| current mouse x position.
void | setY (float y)
virtual float | getY () const
| current mouse y position.
void | setButtonMak (unsigned int mask)
virtual unsigned int | getButtonMask () const
| current mouse button state
virtual double | time () const
| time in seconds of event.
virtual unsigned int | getModKeyMask () const
| current modkey state
void | adaptResize (double t, float Xmin, float Ymin, float Xmax, float Ymax)
| method for adapting resize events.
void | adaptMouseScroll (double t, Producer::KeyboardMouseCallback::ScrollingMotion sm)
| method for adapting mouse scroll wheel events.
void | adaptMouseMotion (double t, float x, float y)
| method for adapting mouse motion events whilst mouse buttons are pressed.
void | adaptButtonPress (double t, float x, float y, unsigned int button)
void | adaptButtonRelease (double t, float x, float y, unsigned int button)
void | adaptKeyPress (double t, Producer::KeySymbol key)
| method for adapting keyboard events.
void | adaptKeyRelease (double t, Producer::KeySymbol key)
void | adaptFrame (double t)
| method for adapting frame events, i.e.
void | copyStaticVariables ()
## Static Public Member Functions
void | setWindowSize (float Xmin, float Ymin, float Xmax, float Ymax)
| static method for setting window dimensions.
void | setButtonMask (unsigned int buttonMask)
| static method for setting button state.
## Public Attributes
EventType | _eventType
int | _key
int | _button
float | _Xmin
float | _Xmax
float | _Ymin
float | _Ymax
float | _mx
float | _my
unsigned int | _buttonMask
unsigned int | _modKeyMask
double | _time
## Static Public Attributes
unsigned int | _s_accumulatedButtonMask
int | _s_button
float | _s_Xmin
float | _s_Xmax
float | _s_Ymin
float | _s_Ymax
float | _s_mx
float | _s_my
int | _s_modKeyMask

## Detailed Description

Class for adapting Producer events so that they can be used as input to osgGA::CameraManipulators.

## Constructor & Destructor Documentation

osgProducer::EventAdapter::EventAdapter | ( |  | ) |

virtual osgProducer::EventAdapter::~EventAdapter | ( |  | ) | `[inline, virtual]`

## Member Function Documentation

void osgProducer::EventAdapter::adaptButtonPress | ( | double | t,
|  | float | x,
|  | float | y,
|  | unsigned int | button
| ) |

void osgProducer::EventAdapter::adaptButtonRelease | ( | double | t,
|  | float | x,
|  | float | y,
|  | unsigned int | button
| ) |

void osgProducer::EventAdapter::adaptFrame | ( | double | t | ) |

| method for adapting frame events, i.e. idle/display callback.

void osgProducer::EventAdapter::adaptKeyPress | ( | double | t,
|  | Producer::KeySymbol | key
| ) |

| method for adapting keyboard events.

void osgProducer::EventAdapter::adaptKeyRelease | ( | double | t,
|  | Producer::KeySymbol | key
| ) |

void osgProducer::EventAdapter::adaptMouseMotion | ( | double | t,
|  | float | x,
|  | float | y
| ) |

| method for adapting mouse motion events whilst mouse buttons are pressed.

void osgProducer::EventAdapter::adaptMouseScroll | ( | double | t,
|  | Producer::KeyboardMouseCallback::ScrollingMotion | sm
| ) |

| method for adapting mouse scroll wheel events.

void osgProducer::EventAdapter::adaptResize | ( | double | t,
|  | float | Xmin,
|  | float | Ymin,
|  | float | Xmax,
|  | float | Ymax
| ) |

| method for adapting resize events.

void osgProducer::EventAdapter::copyStaticVariables | ( |  | ) |

virtual int osgProducer::EventAdapter::getButton | ( |  | ) | const`[inline, virtual]`

| button pressed/released, return -1 if inappropriate for this event. Implements osgGA::GUIEventAdapter.

virtual unsigned int osgProducer::EventAdapter::getButtonMask | ( |  | ) | const`[inline, virtual]`

| current mouse button state Implements osgGA::GUIEventAdapter.

virtual EventType osgProducer::EventAdapter::getEventType | ( |  | ) | const`[inline, virtual]`

| Get the EventType of the GUI event. Implements osgGA::GUIEventAdapter.

virtual int osgProducer::EventAdapter::getKey | ( |  | ) | const`[inline, virtual]`

| key pressed, return -1 if inappropriate for this event. Implements osgGA::GUIEventAdapter.

virtual unsigned int osgProducer::EventAdapter::getModKeyMask | ( |  | ) | const`[inline, virtual]`

| current modkey state Implements osgGA::GUIEventAdapter.

virtual float osgProducer::EventAdapter::getX | ( |  | ) | const`[inline, virtual]`

| current mouse x position. Implements osgGA::GUIEventAdapter.

virtual float osgProducer::EventAdapter::getXmax | ( |  | ) | const`[inline, virtual]`

| window maximum x. Implements osgGA::GUIEventAdapter.

virtual float osgProducer::EventAdapter::getXmin | ( |  | ) | const`[inline, virtual]`

| window minimum x. Implements osgGA::GUIEventAdapter.

virtual float osgProducer::EventAdapter::getY | ( |  | ) | const`[inline, virtual]`

| current mouse y position. Implements osgGA::GUIEventAdapter.

virtual float osgProducer::EventAdapter::getYmax | ( |  | ) | const`[inline, virtual]`

| window maximum y. Implements osgGA::GUIEventAdapter.

virtual float osgProducer::EventAdapter::getYmin | ( |  | ) | const`[inline, virtual]`

| window minimum y. Implements osgGA::GUIEventAdapter.

void osgProducer::EventAdapter::setButtonMak | ( | unsigned int | mask | ) | `[inline]`

void osgProducer::EventAdapter::setButtonMask | ( | unsigned int | buttonMask | ) | `[static]`

| static method for setting button state.

void osgProducer::EventAdapter::setKey | ( | int | key | ) | `[inline]`

void osgProducer::EventAdapter::setWindowSize | ( | float | Xmin,
|  | float | Ymin,
|  | float | Xmax,
|  | float | Ymax
| ) | `[static]`

| static method for setting window dimensions.

void osgProducer::EventAdapter::setX | ( | float | x | ) | `[inline]`

void osgProducer::EventAdapter::setY | ( | float | y | ) | `[inline]`

virtual double osgProducer::EventAdapter::time | ( |  | ) | const`[inline, virtual]`

| time in seconds of event. Implements osgGA::GUIEventAdapter.

## Member Data Documentation

int osgProducer::EventAdapter::_button

unsigned int osgProducer::EventAdapter::_buttonMask

EventType osgProducer::EventAdapter::_eventType

int osgProducer::EventAdapter::_key

unsigned int osgProducer::EventAdapter::_modKeyMask

float osgProducer::EventAdapter::_mx

float osgProducer::EventAdapter::_my

unsigned int osgProducer::EventAdapter::_s_accumulatedButtonMask`[static]`

int osgProducer::EventAdapter::_s_button`[static]`

int osgProducer::EventAdapter::_s_modKeyMask`[static]`

float osgProducer::EventAdapter::_s_mx`[static]`

float osgProducer::EventAdapter::_s_my`[static]`

float osgProducer::EventAdapter::_s_Xmax`[static]`

float osgProducer::EventAdapter::_s_Xmin`[static]`

float osgProducer::EventAdapter::_s_Ymax`[static]`

float osgProducer::EventAdapter::_s_Ymin`[static]`

double osgProducer::EventAdapter::_time

float osgProducer::EventAdapter::_Xmax

float osgProducer::EventAdapter::_Xmin

float osgProducer::EventAdapter::_Ymax

float osgProducer::EventAdapter::_Ymin

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

- EventAdapter