record AL_JOYSTICK_INFO

DescriptionHierarchyFieldsMethodsProperties

Unit

Declaration

type AL_JOYSTICK_INFO = record

Description

information about an entire joystick.

Each joystick will provide one or more stick inputs, of varying types. These can be digital controls which snap to specific positions (eg. a gamepad controller, the coolie hat on a Flightstick Pro or Wingman Extreme, or a normal joystick which hasn't yet been calibrated), or they can be full analogue inputs with a smooth range of motion. Sticks may also have different numbers of axes, for example a normal directional control has two, but the Flightstick Pro throttle is only a single axis, and it is possible that the system could be extended in the future to support full 3d controllers.

The joystick flags field may contain any combination of the bit flags:

AL_JOYFLAG_DIGITAL

This control is currently providing digital input.

AL_JOYFLAG_ANALOGUE

This control is currently providing analogue input.

AL_JOYFLAG_CALIB_DIGITAL

This control will be capable of providing digital input once it has been calibrated, but is not doing this at the moment.

AL_JOYFLAG_CALIB_ANALOGUE

This control will be capable of providing analogue input once it has been calibrated, but is not doing this at the moment.

AL_JOYFLAG_CALIBRATE

Indicates that this control needs to be calibrated. Many devices require multiple calibration steps, so you should call the al_calibrate_joystick function from a loop until this flag is cleared.

AL_JOYFLAG_SIGNED

Indicates that the analogue axis position is in signed format, ranging from -128 to 128. This is the case for all 2d directional controls.

AL_JOYFLAG_UNSIGNED

Indicates that the analogue axis position is in unsigned format, ranging from 0 to 255. This is the case for all 1d throttle controls.

See also
al_joy
Global array of joystick state information, which is updated by the al_poll_joystick function.

Overview

Fields

flags: AL_INT;
num_sticks: AL_INT;
num_buttons: AL_INT;
stick: ARRAY [0..(AL_MAX_JOYSTICK_STICKS)-1] OF AL_JOYSTICK_STICK_INFO;
button: ARRAY [0..(AL_MAX_JOYSTICK_BUTTONS)-1] OF AL_JOYSTICK_BUTTON_INFO;

Description

Fields

flags: AL_INT;

status flags for this joystick.

num_sticks: AL_INT;

how many stick inputs?

num_buttons: AL_INT;

how many buttons?

stick: ARRAY [0..(AL_MAX_JOYSTICK_STICKS)-1] OF AL_JOYSTICK_STICK_INFO;

stick state information.

See also
AL_JOYSTICK_STICK_INFO
information about one or more axis (a slider or directional control)
button: ARRAY [0..(AL_MAX_JOYSTICK_BUTTONS)-1] OF AL_JOYSTICK_BUTTON_INFO;

button state information. .

See also
AL_JOYSTICK_BUTTON_INFO
information about a joystick button.

Generated by PasDoc 0.13.0 on 2016-07-20 12:01:36