layout: doc title: “Starboard Module Reference: input.h”

Defines input events and associated data types.

Enums

SbInputDeviceType

Identifies possible input subsystem types. The types of events that each device type produces correspond to SbInputEventType values.

Values

  • kSbInputDeviceTypeGesture - Input from a gesture-detection mechanism. Examples include Kinect,Wiimotes, etc...
    Produces |Move|, |Press| and |Unpress| events.
  • kSbInputDeviceTypeGamepad - Input from a gamepad, following the layout provided in the W3C Web GamepadAPI. [https://www.w3.org/TR/gamepad/]
    Produces |Move|, |Press| and |Unpress| events.
  • kSbInputDeviceTypeKeyboard - Keyboard input from a traditional keyboard or game controller chatpad.
    Produces |Press| and |Unpress| events.
  • kSbInputDeviceTypeMicrophone - Input from a microphone that would provide audio data to the caller, whomay then find some way to detect speech or other sounds within it. It mayhave processed or filtered the audio in some way before it arrives.
    Produces |Audio| events.
  • kSbInputDeviceTypeMouse - Input from a traditional mouse.
    Produces |Move|, |Press|, and |Unpress| events.
  • kSbInputDeviceTypeRemote - Input from a TV remote-control-style device.
    Produces |Press| and |Unpress| events.
  • kSbInputDeviceTypeSpeechCommand - Input from a speech command analyzer, which is some hardware or softwarethat, given a set of known phrases, activates when one of the registeredphrases is heard.
    Produces |Command| events.
  • kSbInputDeviceTypeTouchScreen - Input from a single- or multi-touchscreen.
    Produces |Move|, |Press|, and |Unpress| events.
  • kSbInputDeviceTypeTouchPad - Input from a touchpad that is not masquerading as a mouse.
    Produces |Move|, |Press|, and |Unpress| events.

SbInputEventType

The action that an input event represents.

Values

  • kSbInputEventTypeAudio - Receipt of Audio. Some audio data was received by the input microphone.
  • kSbInputEventTypeCommand - Receipt of a command. A command was received from some semantic source,like a speech recognizer.
  • kSbInputEventTypeGrab - Grab activation. This event type is deprecated.
  • kSbInputEventTypeMove - Device Movement. In the case of |Mouse|, and perhaps |Gesture|, themovement tracks an absolute cursor position. In the case of |TouchPad|,only relative movements are provided.
  • kSbInputEventTypePress - Key or button press activation. This could be a key on a keyboard, a buttonon a mouse or game controller, a push from a touch screen, or a gesture. An|Unpress| event is subsequently delivered when the |Press| eventterminates, such as when the key/button/finger is raised. Injecting repeatpresses is up to the client.
  • kSbInputEventTypeUngrab - Grab deactivation. This event type is deprecated.
  • kSbInputEventTypeUnpress - Key or button deactivation. The counterpart to the |Press| event, thisevent is sent when the key or button being pressed is released.
  • kSbInputEventTypeWheel - Wheel movement. Provides relative movements of the |Mouse| wheel.

Structs

SbInputData

Event data for kSbEventTypeInput events.

Members

SbInputVector

A 2-dimensional vector used to represent points and motion vectors.

Members