utility 2026.1.9
A comprehensive C++ utilities library tailored for the development of modern desktop and extended reality (XR) applications.
Loading...
Searching...
No Matches
utility::event::HandThumbStickEvent Class Reference

Hand thumbstick event. More...

#include <headers/utility/event/hand_thumb_stick_event.hpp>

Inheritance diagram for utility::event::HandThumbStickEvent:
Collaboration diagram for utility::event::HandThumbStickEvent:

Classes

class  Factory
 Factory for creating HandThumbStickEvent instances. More...
 

Public Member Functions

 HandThumbStickEvent (void)
 Default constructor.
 
HandThumbStickEventsetX (const float x) noexcept
 Set X axis value.
 
float getX (void) const noexcept
 Get X axis value.
 
HandThumbStickEventsetY (const float y) noexcept
 Set Y axis value.
 
float getY (void) const noexcept
 Get Y axis value.
 
HandThumbStickEventsetAxis (const float x, const float y) noexcept
 Set both axis values.
 
HandThumbStickEventsetTouched (const bool touched) noexcept
 Set touched state.
 
bool isTouched (void) const noexcept
 Get touched state.
 
HandThumbStickEventsetButtonPressed (const bool clicked) noexcept
 Set clicked state.
 
bool isButtonPressed (void) const noexcept
 Get clicked state.
 
- Public Member Functions inherited from utility::event::HandEvent
 HandEvent (void)
 Default constructor.
 
virtual ~HandEvent (void) override
 Default destructor.
 
HandEventsetHandType (const HandType handType) noexcept
 Set the type of hand involved in the event.
 
HandType getHandType (void) const noexcept
 Get the type of hand involved in the event.
 
HandEventsetPose (const graphic::PoseF &pose) noexcept
 Set the pose of the hand.
 
graphic::PoseF getPose (void) const noexcept
 Get the pose of the hand.
 
HandEventsetAim (const graphic::PoseF &aim) noexcept
 Set aim pose.
 
graphic::PoseF getAim (void) const noexcept
 Get aim pose.
 
HandEventsetGrip (const graphic::PoseF &grip) noexcept
 Set grip pose.
 
graphic::PoseF getGrip (void) const noexcept
 Get grip pose.
 
HandEventsetGripSurface (const graphic::PoseF &gripSurface) noexcept
 Set grip_surface pose.
 
graphic::PoseF getGripSurface (void) const noexcept
 Get grip_surface pose.
 
- Public Member Functions inherited from utility::event::Event
 Event (void)=default
 Default constructor.
 
virtual ~Event (void)=default
 Virtual destructor.
 

Additional Inherited Members

- Public Types inherited from utility::event::HandEvent
enum class  HandType { Unknown = 0 , Left = 1 , Right = 2 }
 Hand types for hand events. Defines the type of hand involved in the event (e.g., left or right). More...
 

Detailed Description

Hand thumbstick event.

Definition at line 35 of file hand_thumb_stick_event.hpp.

Member Function Documentation

◆ getX()

float utility::event::HandThumbStickEvent::getX ( void  ) const
noexcept

Get X axis value.

Returns
Axis value in [-1, 1].

Definition at line 53 of file hand_thumb_stick_event.cpp.

◆ getY()

float utility::event::HandThumbStickEvent::getY ( void  ) const
noexcept

Get Y axis value.

Returns
Axis value in [-1, 1].

Definition at line 64 of file hand_thumb_stick_event.cpp.

◆ isButtonPressed()

bool utility::event::HandThumbStickEvent::isButtonPressed ( void  ) const
noexcept

Get clicked state.

Returns
True if clicked.

Definition at line 96 of file hand_thumb_stick_event.cpp.

◆ isTouched()

bool utility::event::HandThumbStickEvent::isTouched ( void  ) const
noexcept

Get touched state.

Returns
True if touched.

Definition at line 84 of file hand_thumb_stick_event.cpp.

◆ setAxis()

HandThumbStickEvent & utility::event::HandThumbStickEvent::setAxis ( const float  x,
const float  y 
)
noexcept

Set both axis values.

Parameters
xX axis value.
yY axis value.
Returns
Reference to this HandThumbStickEvent.

Definition at line 69 of file hand_thumb_stick_event.cpp.

◆ setButtonPressed()

HandThumbStickEvent & utility::event::HandThumbStickEvent::setButtonPressed ( const bool  clicked)
noexcept

Set clicked state.

Parameters
clickedTrue if clicked.
Returns
Reference to this HandThumbStickEvent.

Definition at line 90 of file hand_thumb_stick_event.cpp.

◆ setTouched()

HandThumbStickEvent & utility::event::HandThumbStickEvent::setTouched ( const bool  touched)
noexcept

Set touched state.

Parameters
touchedTrue if touched.
Returns
Reference to this HandThumbStickEvent.

Definition at line 78 of file hand_thumb_stick_event.cpp.

◆ setX()

HandThumbStickEvent & utility::event::HandThumbStickEvent::setX ( const float  x)
noexcept

Set X axis value.

Parameters
xAxis value.
Returns
Reference to this HandThumbStickEvent.

Definition at line 47 of file hand_thumb_stick_event.cpp.

◆ setY()

HandThumbStickEvent & utility::event::HandThumbStickEvent::setY ( const float  y)
noexcept

Set Y axis value.

Parameters
yAxis value.
Returns
Reference to this HandThumbStickEvent.

Definition at line 58 of file hand_thumb_stick_event.cpp.


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