Open 3D Engine AzFramework API Reference 23.10.0
O3DE is an open-source, fully-featured, high-fidelity, modular 3D engine for building games and simulations, available to every industry.
AzFramework::InputDeviceGamepad::Implementation::RawGamepadState Struct Reference

Platform agnostic representation of a raw game-pad state. More...

#include <InputDeviceGamepad.h>

Public Member Functions

 RawGamepadState (const DigitalButtonIdByBitMaskMap &digitalButtonIdsByBitMask)
 
 AZ_DISABLE_COPY_MOVE (RawGamepadState)
 
 ~RawGamepadState ()=default
 Default destructor.
 
void Reset ()
 Reset the raw gamepad state.
 
float GetLeftTriggerAdjustedForDeadZoneAndNormalized () const
 
float GetRightTriggerAdjustedForDeadZoneAndNormalized () const
 
AZ::Vector2 GetLeftThumbStickAdjustedForDeadZoneAndNormalized () const
 
AZ::Vector2 GetRightThumbStickAdjustedForDeadZoneAndNormalized () const
 
AZ::Vector2 GetLeftThumbStickNormalizedValues () const
 
AZ::Vector2 GetRightThumbStickNormalizedValues () const
 

Public Attributes

const DigitalButtonIdByBitMaskMap m_digitalButtonIdsByBitMask
 The map of digital button ids by bitmask.
 
AZ::u32 m_digitalButtonStates
 The state of all digital buttons.
 
float m_triggerButtonLState
 The state of the left trigger button.
 
float m_triggerButtonRState
 The state of the right trigger button.
 
float m_thumbStickLeftXState
 The state of the left thumb-stick x-axis.
 
float m_thumbStickLeftYState
 The state of the left thumb-stick y-axis.
 
float m_thumbStickRightXState
 The state of the right thumb-stick x-axis.
 
float m_thumbStickRightYState
 The state of the right thumb-stick y-axis.
 
float m_triggerMaximumValue
 The analog trigger maximum value.
 
float m_triggerDeadZoneValue
 The analog trigger dead zone value.
 
float m_thumbStickMaximumValue
 The thumb-stick maximum radius value.
 
float m_thumbStickLeftDeadZone
 The left thumb-stick radial dead zone value.
 
float m_thumbStickRightDeadZone
 The right thumb-stick radial dead zone value.
 

Detailed Description

Platform agnostic representation of a raw game-pad state.

Constructor & Destructor Documentation

◆ RawGamepadState()

AzFramework::InputDeviceGamepad::Implementation::RawGamepadState::RawGamepadState ( const DigitalButtonIdByBitMaskMap digitalButtonIdsByBitMask)

Constructor

Parameters
[in]digitalButtonIdsByBitMaskA map of digital button ids by bitmask

Member Function Documentation

◆ GetLeftThumbStickAdjustedForDeadZoneAndNormalized()

AZ::Vector2 AzFramework::InputDeviceGamepad::Implementation::RawGamepadState::GetLeftThumbStickAdjustedForDeadZoneAndNormalized ( ) const

Get the left thumb-stick values adjusted for the dead zone and normalized

Returns
The left thumb-stick values adjusted for the dead zone and normalized

◆ GetLeftThumbStickNormalizedValues()

AZ::Vector2 AzFramework::InputDeviceGamepad::Implementation::RawGamepadState::GetLeftThumbStickNormalizedValues ( ) const

Get the left thumb-stick values normalized with no dead zone applied

Returns
The left thumb-stick values normalized with no dead zone applied

◆ GetLeftTriggerAdjustedForDeadZoneAndNormalized()

float AzFramework::InputDeviceGamepad::Implementation::RawGamepadState::GetLeftTriggerAdjustedForDeadZoneAndNormalized ( ) const

Get the left trigger value adjusted for the dead zone and normalized

Returns
The left trigger value adjusted for the dead zone and normalized

◆ GetRightThumbStickAdjustedForDeadZoneAndNormalized()

AZ::Vector2 AzFramework::InputDeviceGamepad::Implementation::RawGamepadState::GetRightThumbStickAdjustedForDeadZoneAndNormalized ( ) const

Get the right thumb-stick values adjusted for the dead zone and normalized

Returns
The right thumb-stick values adjusted for the dead zone and normalized

◆ GetRightThumbStickNormalizedValues()

AZ::Vector2 AzFramework::InputDeviceGamepad::Implementation::RawGamepadState::GetRightThumbStickNormalizedValues ( ) const

Get the right thumb-stick values normalized with no dead zone applied

Returns
The right thumb-stick values normalized with no dead zone applied

◆ GetRightTriggerAdjustedForDeadZoneAndNormalized()

float AzFramework::InputDeviceGamepad::Implementation::RawGamepadState::GetRightTriggerAdjustedForDeadZoneAndNormalized ( ) const

Get the right trigger value adjusted for the dead zone and normalized

Returns
The right trigger value adjusted for the dead zone and normalized

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