Orxonox  0.0.5 Codename: Arcturus
Public Member Functions | Static Public Attributes | List of all members
orxonox::InputHandler Class Reference

Base class for all input handlers like KeyBinder, InputBuffer, etc. More...

#include </home/jenkins/workspace/orxonox_doxygen_trunk/src/libraries/core/input/InputHandler.h>

Inheritance diagram for orxonox::InputHandler:
orxonox::GUIManager orxonox::InputBuffer orxonox::KeyBinder orxonox::KeyDetector

Public Member Functions

virtual ~InputHandler ()=default
 
virtual void allDevicesUpdated (float dt)
 
virtual void axisMoved (unsigned int joyStick, unsigned int axis, float value)
 
template<class T >
void buttonEvent (unsigned int device, T button, ButtonEvent::TPress)
 
template<class T >
void buttonEvent (unsigned int device, T button, ButtonEvent::TRelease)
 
template<class T >
void buttonEvent (unsigned int device, T button, ButtonEvent::THold)
 
virtual void buttonHeld (const KeyEvent &evt)
 
virtual void buttonHeld (MouseButtonCode::ByEnum button)
 
virtual void buttonHeld (unsigned int joyStick, JoyStickButtonCode::ByEnum button)
 
virtual void buttonPressed (const KeyEvent &evt)
 
virtual void buttonPressed (MouseButtonCode::ByEnum button)
 
virtual void buttonPressed (unsigned int joyStick, JoyStickButtonCode::ByEnum button)
 
virtual void buttonReleased (const KeyEvent &evt)
 
virtual void buttonReleased (MouseButtonCode::ByEnum button)
 
virtual void buttonReleased (unsigned int joyStick, JoyStickButtonCode::ByEnum button)
 
virtual void joyStickUpdated (unsigned int joyStick, float dt)
 
virtual void keyboardUpdated (float dt)
 
virtual void mouseMoved (IntVector2 abs, IntVector2 rel, IntVector2 clippingSize)
 
virtual void mouseScrolled (int abs, int rel)
 
virtual void mouseUpdated (float dt)
 

Static Public Attributes

static InputHandler EMPTY
 Use this input handler if you want to occupy a device in an input state. More...
 

Detailed Description

Base class for all input handlers like KeyBinder, InputBuffer, etc.

Derive from this class if you wish to receive input events. But keep in mind that this is pointless without first having an InputState.

Note
The definitions for the button events with the weird arguments are simply to avoid redundant code in the input devices.

Constructor & Destructor Documentation

virtual orxonox::InputHandler::~InputHandler ( )
virtualdefault

Member Function Documentation

virtual void orxonox::InputHandler::allDevicesUpdated ( float  dt)
inlinevirtual

Reimplemented in orxonox::KeyBinder.

virtual void orxonox::InputHandler::axisMoved ( unsigned int  joyStick,
unsigned int  axis,
float  value 
)
inlinevirtual

Reimplemented in orxonox::KeyBinder.

template<class T >
void orxonox::InputHandler::buttonEvent ( unsigned int  device,
button,
ButtonEvent::TPress   
)
inline
template<class T >
void orxonox::InputHandler::buttonEvent ( unsigned int  device,
button,
ButtonEvent::TRelease   
)
inline
template<class T >
void orxonox::InputHandler::buttonEvent ( unsigned int  device,
button,
ButtonEvent::THold   
)
inline
virtual void orxonox::InputHandler::buttonHeld ( const KeyEvent evt)
inlinevirtual

Reimplemented in orxonox::InputBuffer, and orxonox::KeyBinder.

virtual void orxonox::InputHandler::buttonHeld ( MouseButtonCode::ByEnum  button)
inlinevirtual

Reimplemented in orxonox::KeyBinder.

virtual void orxonox::InputHandler::buttonHeld ( unsigned int  joyStick,
JoyStickButtonCode::ByEnum  button 
)
inlinevirtual

Reimplemented in orxonox::KeyBinder.

virtual void orxonox::InputHandler::buttonPressed ( const KeyEvent evt)
inlinevirtual
virtual void orxonox::InputHandler::buttonPressed ( MouseButtonCode::ByEnum  button)
inlinevirtual

Reimplemented in orxonox::GUIManager, and orxonox::KeyBinder.

virtual void orxonox::InputHandler::buttonPressed ( unsigned int  joyStick,
JoyStickButtonCode::ByEnum  button 
)
inlinevirtual

Reimplemented in orxonox::KeyBinder.

virtual void orxonox::InputHandler::buttonReleased ( const KeyEvent evt)
inlinevirtual

Reimplemented in orxonox::GUIManager, and orxonox::KeyBinder.

virtual void orxonox::InputHandler::buttonReleased ( MouseButtonCode::ByEnum  button)
inlinevirtual

Reimplemented in orxonox::GUIManager, and orxonox::KeyBinder.

virtual void orxonox::InputHandler::buttonReleased ( unsigned int  joyStick,
JoyStickButtonCode::ByEnum  button 
)
inlinevirtual

Reimplemented in orxonox::KeyBinder.

virtual void orxonox::InputHandler::joyStickUpdated ( unsigned int  joyStick,
float  dt 
)
inlinevirtual

Reimplemented in orxonox::KeyBinder.

virtual void orxonox::InputHandler::keyboardUpdated ( float  dt)
inlinevirtual

Reimplemented in orxonox::InputBuffer.

virtual void orxonox::InputHandler::mouseMoved ( IntVector2  abs,
IntVector2  rel,
IntVector2  clippingSize 
)
inlinevirtual

Reimplemented in orxonox::GUIManager, and orxonox::KeyBinder.

virtual void orxonox::InputHandler::mouseScrolled ( int  abs,
int  rel 
)
inlinevirtual

Reimplemented in orxonox::GUIManager, and orxonox::KeyBinder.

virtual void orxonox::InputHandler::mouseUpdated ( float  dt)
inlinevirtual

Reimplemented in orxonox::KeyBinder.

Member Data Documentation

InputHandler orxonox::InputHandler::EMPTY
static

Use this input handler if you want to occupy a device in an input state.


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