Guiliani  Version 2.5 revision 7293 (documentation build 13)
CGUIInputDeviceUnix_Powermate Class Reference

Reads input of the powermate. More...

#include <GUIInputDeviceUnixPowermate.h>

Inheritance diagram for CGUIInputDeviceUnix_Powermate:

Public Member Functions

CGUIEventGetEvent (eC_UInt uiIdleTime)
 
void StopIdle ()
 
- Public Member Functions inherited from CGUIInputMedia
eC_Bool GetDebugMode () const
 
virtual CGUIEventGetEvent (eC_UInt uiIdleTime)=0
 
virtual void GetOffset (eC_Int &riOffsetX, eC_Int &riOffsetY) const
 
Rotation_t GetRotation () const
 
virtual void GetSize (eC_Int &riSizeX, eC_Int &riSizeY) const
 
eC_UInt GetSleepInterval () const
 
void SetDebugMode (const eC_Bool &bDebugMode)
 
virtual void SetOffset (const eC_Int &iOffsetX, const eC_Int &iOffsetY)
 
void SetRotation (const Rotation_t &eRotation)
 
virtual void SetSize (const eC_Int &iSizeX, const eC_Int &iSizeY)
 
void SetSleepInterval (const eC_UInt &uiInterval)
 
virtual void StopIdle ()
 

Static Public Member Functions

static void CreateInstance (const char *cpcPMDevice, eC_Int iSensitivity)
 
- Static Public Member Functions inherited from CGUIInputMedia
static void DeleteInstance ()
 

Public Attributes

CGUIInputThreadDeviceUnix_Powermate m_kPowermateThread
 Thread Powermate. More...
 

Static Public Attributes

static eC_TListDoubleLinked< CGUIEvent * > ms_kEventQueue
 The event queue.
 

Friends

class CGUIInputThreadDeviceUnix_Powermate
 friend
 

Additional Inherited Members

- Public Types inherited from CGUIInputMedia
enum  Rotation_t { ROTATION_0 , ROTATION_90 , ROTATION_180 , ROTATION_270 }
 rotation of input-device
 
- Protected Member Functions inherited from CGUIInputMedia
 CGUIInputMedia ()
 
virtual ~CGUIInputMedia ()
 
- Protected Attributes inherited from CGUIInputMedia
eC_Bool m_bDebugMode
 debug-mode for input-device
 
eC_Bool m_bStopIdle
 stop idle when waiting for events
 
Rotation_t m_eRotation
 current rotation used for input-device
 
eC_Int m_iOffsetX
 x-offset
 
eC_Int m_iOffsetY
 y-offset
 
eC_Int m_iSizeX
 width
 
eC_Int m_iSizeY
 height
 
eC_UInt m_uiSleepInterval
 sleep interval
 

Detailed Description

Reads input of the powermate.

This input wrapper starts a thread (CGUIInputThreadDeviceUnixPowermate) which reads input of the powermate GUIEvents are created and added to an event queue. The input wrapper reads those events from the queue to handle them.

Member Function Documentation

◆ CreateInstance()

static void CGUIInputDeviceUnix_Powermate::CreateInstance ( const char *  cpcPMDevice,
eC_Int  iSensitivity 
)
static

Creates the singleton instance.

Parameters
cpcPMDevicePath to keyboard input device. If NULL device will not be used.
iSensitivitySensitivity of the wheel. The more the value iSensitivity, the less the Sensitivity.

◆ GetEvent()

CGUIEvent * CGUIInputDeviceUnix_Powermate::GetEvent ( eC_UInt  uiIdleTime)
virtual

Retrieves a platform-specific event and creates an appropriate Guiliani event. The supplied parameter specifies the time in milliseconds until the next processing of animation timers or commands is required. An input media may use this to avoid unnecessary event polling. It MUST return from GetEvent after the specified time, though.

Parameters
uiIdleTimespecifies the maximum idle time in ms.
Returns
Pointer to a newly generated Guiliani event, or NULL if nothing happened.

Implements CGUIInputMedia.

◆ StopIdle()

void CGUIInputDeviceUnix_Powermate::StopIdle ( )
virtual

Forces the input media to quit idling immediately. Called by the framework if the input media is requested to stop idling immediately. Classes derived from GUIInputMedia should implement StopIdle in such a way, that it interrupts any idling/sleeping code in GetEvent(). virtual is needed if sub-classes need to do extra stuff

Reimplemented from CGUIInputMedia.

Member Data Documentation

◆ m_kPowermateThread

CGUIInputThreadDeviceUnix_Powermate CGUIInputDeviceUnix_Powermate::m_kPowermateThread

Thread Powermate.

This thread polls the Griffin PowerMate device and creates GUIEvents. new events are added to the event queue.


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