VMUPro SDK v1.0.0
Application Development SDK for the VMUPro
|
VMUPro button input API. More...
#include <stdint.h>
#include <stdbool.h>
Go to the source code of this file.
Enumerations | |
enum | vmupro_btn_t { DPad_Up , DPad_Down , DPad_Right , DPad_Left , Btn_Power , Btn_Mode , Btn_A , Btn_B , Btn_Bottom } |
Predefined button values. More... | |
Functions | |
void | vmupro_btn_read () |
Call every frame, or when a new dialogue opens to read the button inputs. Press & release actions are automatically tracked. | |
bool | vmupro_btn_held (vmupro_btn_t btn) |
Check if a button is currently held. | |
bool | vmupro_btn_pressed (vmupro_btn_t btn) |
Check if a button is currently held but was not held last time vmupro_btn_read() was called. | |
bool | vmupro_btn_released (vmupro_btn_t btn) |
Check if a button is currently not heldheld but was held last time vmupro_btn_read() was called. | |
bool | vmupro_btn_anything_held () |
Check if any button is currently held/pressed Useful between menus to wait untill the user has finished pressing buttons. | |
bool | vmupro_btn_confirm_pressed () |
Was the user-configurable confirm button (A or B) pressed since the last vmupro_btn_read() | |
bool | vmupro_btn_confirm_released () |
Was the user-configurable confirm button (A or B) released since the last vmupro_btn_read() | |
bool | vmupro_btn_dismiss_pressed () |
Was the user-configurable dismiss button (A or B) pressed since the last vmupro_btn_read() | |
bool | vmupro_btn_dismiss_released () |
Was the user-configurable dismiss button (A or B) released since the last vmupro_btn_read() | |
VMUPro button input API.
This header provides the API to read and update button inputs. It includes functions to read user-configurable confirm/dismiss inputs, and functions to automatically track press/release/held states
Definition in file vmupro_buttons.h.
enum vmupro_btn_t |
Predefined button values.
Enumerator | |
---|---|
DPad_Up | |
DPad_Down | |
DPad_Right | |
DPad_Left | |
Btn_Power | |
Btn_Mode | |
Btn_A | |
Btn_B | |
Btn_Bottom |
Definition at line 26 of file vmupro_buttons.h.
bool vmupro_btn_anything_held | ( | ) |
Check if any button is currently held/pressed Useful between menus to wait untill the user has finished pressing buttons.
bool vmupro_btn_confirm_pressed | ( | ) |
Was the user-configurable confirm button (A or B) pressed since the last vmupro_btn_read()
bool vmupro_btn_confirm_released | ( | ) |
Was the user-configurable confirm button (A or B) released since the last vmupro_btn_read()
bool vmupro_btn_dismiss_pressed | ( | ) |
Was the user-configurable dismiss button (A or B) pressed since the last vmupro_btn_read()
bool vmupro_btn_dismiss_released | ( | ) |
Was the user-configurable dismiss button (A or B) released since the last vmupro_btn_read()
bool vmupro_btn_held | ( | vmupro_btn_t | btn | ) |
Check if a button is currently held.
The | button to check |
bool vmupro_btn_pressed | ( | vmupro_btn_t | btn | ) |
Check if a button is currently held but was not held last time vmupro_btn_read() was called.
The | button to check |
void vmupro_btn_read | ( | ) |
Call every frame, or when a new dialogue opens to read the button inputs. Press & release actions are automatically tracked.
bool vmupro_btn_released | ( | vmupro_btn_t | btn | ) |
Check if a button is currently not heldheld but was held last time vmupro_btn_read() was called.
The | button to check |