ScummVM API documentation
hpl::Mouse Class Reference
Inheritance diagram for hpl::Mouse:
hpl::iInputDevice

Public Member Functions

 Mouse (LowLevelInput *apLowLevelInputSDL, iLowLevelGraphics *apLowLevelGraphics)
 
bool ButtonIsDown (eMButton)
 
cVector2f GetAbsPosition ()
 
cVector2f GetRelPosition ()
 
void Reset ()
 
void SetSmoothProperties (float afMinPercent, float afMaxPercent, unsigned int alBufferSize)
 
void Update ()
 
- Public Member Functions inherited from hpl::iInputDevice
 iInputDevice (tString asName, eInputDeviceType aType)
 
tString GetName ()
 
eInputDeviceType GetType ()
 

Member Function Documentation

◆ ButtonIsDown()

bool hpl::Mouse::ButtonIsDown ( eMButton  )

Check if a mouse button is down

Parameters
eMButtonthe button to check
Returns

◆ GetAbsPosition()

cVector2f hpl::Mouse::GetAbsPosition ( )

Get the absolute pos of the mouse.

Returns

◆ GetRelPosition()

cVector2f hpl::Mouse::GetRelPosition ( )

Get the relative movement.

Returns

◆ Reset()

void hpl::Mouse::Reset ( )

Reset smoothing and relative movement.

◆ SetSmoothProperties()

void hpl::Mouse::SetSmoothProperties ( float  afMinPercent,
float  afMaxPercent,
unsigned int  alBufferSize 
)

Set parameters for mouse smoothing

Parameters
afMinPercentInfluence of the oldest position.
afMaxPercentInfluence of the latest position.
alBufferSizenumber of saved positions, 1 = no smoothing

◆ Update()

void hpl::Mouse::Update ( )
virtual

Update the device, called by cInput

Implements hpl::iInputDevice.


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