Package gaiasky.input
Class InputUtils
java.lang.Object
gaiasky.input.InputUtils
Utilities for the input system.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic int
getGlfwKeyCode
(int gdxKeyCode) Returns the GLFW key code corresponding to a GDX key code.static int
keyStringToKeyCode
(String keyString) Converts string representations of keys into key codes (seeInput.Keys
).static String
physicalKeyCodeToLogicalKeyString
(int keyCode) Converts GDX physical key codes to GLFW logical strings.static int
physicalToLogicalKeyCode
(int physicalKeyCode)
-
Constructor Details
-
InputUtils
public InputUtils()
-
-
Method Details
-
physicalToLogicalKeyCode
public static int physicalToLogicalKeyCode(int physicalKeyCode) -
physicalKeyCodeToLogicalKeyString
Converts GDX physical key codes to GLFW logical strings.- Parameters:
keyCode
- The physical key code.- Returns:
- The string representing the logical key.
-
getGlfwKeyCode
public static int getGlfwKeyCode(int gdxKeyCode) Returns the GLFW key code corresponding to a GDX key code.- Parameters:
gdxKeyCode
- The GDX key code.- Returns:
- The GLFW key code.
-
keyStringToKeyCode
Converts string representations of keys into key codes (seeInput.Keys
).- Parameters:
keyString
- The string representation.- Returns:
- The key code.
-