#include "../animate.h"
#include "../draw.h"
Go to the source code of this file.
|
| int | gm_joystick_anim (double x, double y, double radius, gmPos *pos, gmPos *vpos) |
| | Creates and renders an animated joystick widget that can be manipulated with the mouse.
|
| int | gmw_joystick (double x, double y, double radius, gmPos *pos) |
| | Creates and renders a joystick widget that can be manipulated with the mouse.
|
◆ gm_joystick_anim()
| int gm_joystick_anim |
( |
double | x, |
|
|
double | y, |
|
|
double | radius, |
|
|
gmPos * | pos, |
|
|
gmPos * | vpos ) |
Creates and renders an animated joystick widget that can be manipulated with the mouse.
- Parameters
-
| x | The x-coordinate of the joystick's center. |
| y | The y-coordinate of the joystick's center. |
| radius | The radius of the joystick base. |
| pos | Pointer to a gmPos structure to store the joystick's logical position (-1 to 1). |
| vpos | Pointer to a gmPos structure for animated visual position (can be NULL to use pos). |
- Returns
- 1 if the joystick is currently hovered, 0 otherwise.
◆ gmw_joystick()
| int gmw_joystick |
( |
double | x, |
|
|
double | y, |
|
|
double | radius, |
|
|
gmPos * | pos ) |
Creates and renders a joystick widget that can be manipulated with the mouse.
- Parameters
-
| x | The x-coordinate of the joystick's center. |
| y | The y-coordinate of the joystick's center. |
| radius | The radius of the joystick base. |
| pos | Pointer to a gmPos structure to store the joystick's logical position (-1 to 1). |
- Returns
- 1 if the joystick is currently hovered, 0 otherwise.
◆ gmwJoystick
Initial value:= {
.enabled = 1,
.scale = 1.0,
.background = 0x3A2A3AE0,
.border = 0x7F4F7FFF,
.focussed = {.scale = 1.05, .border = 0xAA77AAFF},
.active = {.scale = 0.95, .border = 0x7F4F7FFF},
.knob = 0xAA77AAFF,
.knob_border = 0x6F3F6FFF,
.border_width = 0.01}
Global joystick theme instance with default values.