Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface IDeviceInputSystem

Interface for DeviceInputSystem implementations (JS and Native)

Hierarchy

Index

Properties

Readonly onDeviceConnectedObservableSearch playground for onDeviceConnectedObservable

onDeviceConnectedObservable: Observable<{ deviceSlot: number; deviceType: DeviceType }>

Observable for devices being connected

Readonly onDeviceDisconnectedObservableSearch playground for onDeviceDisconnectedObservable

onDeviceDisconnectedObservable: Observable<{ deviceSlot: number; deviceType: DeviceType }>

Observable for devices being disconnected

Readonly onInputChangedObservableSearch playground for onInputChangedObservable

onInputChangedObservable: Observable<IDeviceEvent>

Observable for changes to device input

Methods

disposeSearch playground for dispose

  • dispose(): void
  • Releases all held resources

    Returns void

isDeviceAvailableSearch playground for isDeviceAvailable

  • isDeviceAvailable(deviceType: DeviceType): boolean
  • Check for a specific device in the DeviceInputSystem

    Parameters

    • deviceType: DeviceType

      Type of device to check for

    Returns boolean

    bool with status of device's existence

pollInputSearch playground for pollInput

  • pollInput(deviceType: DeviceType, deviceSlot: number, inputIndex: number): number
  • Checks for current device input value, given an id and input index. Throws exception if requested device not initialized.

    Parameters

    • deviceType: DeviceType

      Enum specifiying device type

    • deviceSlot: number

      "Slot" or index that device is referenced in

    • inputIndex: number

      Id of input to be checked

    Returns number

    Current value of input

Legend

  • Constructor
  • Property
  • Method
  • Property
  • Method
  • Inherited property
  • Inherited method
  • Static property
  • Static method