YARP
Yet Another Robot Platform
 
Loading...
Searching...
No Matches
ButtonState Struct Reference

Public Member Functions

float deadzone (float input, float deadzone) const
 
void render (const ImVec4 &button_active_color, const ImVec4 &button_inactive_color, const ImVec2 &buttonSize, bool hold_active, double joypadDeadzone, const std::vector< float > &joypadAxisValues, const std::vector< bool > &joypadButtonValues, std::vector< double > &outputValues)
 

Public Attributes

std::string alias
 
ButtonType type { ButtonType::REGULAR }
 
std::vector< ImGuiKey > keys
 
std::vector< ButtonValue > values
 
std::vector< ButtonValue > joypadAxisInputs
 
std::vector< int > joypadButtonIndices
 
int col { 0 }
 
bool active { false }
 
bool buttonPressed { false }
 

Detailed Description

Definition at line 57 of file KeyboardJoypad.cpp.

Member Function Documentation

◆ deadzone()

float ButtonState::deadzone ( float  input,
float  deadzone 
) const
inline

Definition at line 68 of file KeyboardJoypad.cpp.

◆ render()

void ButtonState::render ( const ImVec4 &  button_active_color,
const ImVec4 &  button_inactive_color,
const ImVec2 &  buttonSize,
bool  hold_active,
double  joypadDeadzone,
const std::vector< float > &  joypadAxisValues,
const std::vector< bool > &  joypadButtonValues,
std::vector< double > &  outputValues 
)
inline

Definition at line 75 of file KeyboardJoypad.cpp.

Member Data Documentation

◆ active

bool ButtonState::active { false }

Definition at line 65 of file KeyboardJoypad.cpp.

◆ alias

std::string ButtonState::alias

Definition at line 58 of file KeyboardJoypad.cpp.

◆ buttonPressed

bool ButtonState::buttonPressed { false }

Definition at line 66 of file KeyboardJoypad.cpp.

◆ col

int ButtonState::col { 0 }

Definition at line 64 of file KeyboardJoypad.cpp.

◆ joypadAxisInputs

std::vector<ButtonValue> ButtonState::joypadAxisInputs

Definition at line 62 of file KeyboardJoypad.cpp.

◆ joypadButtonIndices

std::vector<int> ButtonState::joypadButtonIndices

Definition at line 63 of file KeyboardJoypad.cpp.

◆ keys

std::vector<ImGuiKey> ButtonState::keys

Definition at line 60 of file KeyboardJoypad.cpp.

◆ type

ButtonType ButtonState::type { ButtonType::REGULAR }

Definition at line 59 of file KeyboardJoypad.cpp.

◆ values

std::vector<ButtonValue> ButtonState::values

Definition at line 61 of file KeyboardJoypad.cpp.


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