Skip to main content

Class: GyroInputDevice

Extra-Helpers.GyroInputDevice

Implements

Methods

IsCompatible

Static IsCompatible(): boolean

Returns

boolean

Defined in

webgi/src/extras/devices/GyroInputDevice.ts:73


getOffsetFromCenter

getOffsetFromCenter(initialIdentity?): Vector2

Parameters

NameTypeDefault value
initialIdentitybooleantrue

Returns

Vector2

Implementation of

IInputDevice.getOffsetFromCenter

Defined in

webgi/src/extras/devices/GyroInputDevice.ts:16


getQuaternion

getQuaternion(initialIdentity, quat?): Quaternion

Parameters

NameType
initialIdentityboolean
quat?Quaternion

Returns

Quaternion

Defined in

webgi/src/extras/devices/GyroInputDevice.ts:27


onScreenOrientationChangeEvent

onScreenOrientationChangeEvent(): void

Returns

void

Defined in

webgi/src/extras/devices/GyroInputDevice.ts:77


onDeviceOrientationChangeEvent

onDeviceOrientationChangeEvent(event): void

Parameters

NameType
eventDeviceOrientationEvent

Returns

void

Defined in

webgi/src/extras/devices/GyroInputDevice.ts:81


addPermissionMessage

addPermissionMessage(): void

Returns

void

Defined in

webgi/src/extras/devices/GyroInputDevice.ts:85


connect

connect(): undefined | boolean

Returns

undefined | boolean

Implementation of

IInputDevice.connect

Defined in

webgi/src/extras/devices/GyroInputDevice.ts:100


askPermission

askPermission(): void

Returns

void

Defined in

webgi/src/extras/devices/GyroInputDevice.ts:116


disconnect

disconnect(): void

Returns

void

Implementation of

IInputDevice.disconnect

Defined in

webgi/src/extras/devices/GyroInputDevice.ts:136


_toQuaternion

Protected _toQuaternion(quat, alpha, beta, gamma, orient, initialIdentity): Quaternion

Parameters

NameType
quatQuaternion
alphanumber
betanumber
gammanumber
orientnumber
initialIdentityboolean

Returns

Quaternion

Defined in

webgi/src/extras/devices/GyroInputDevice.ts:47

Properties

screenOrientation

screenOrientation: any

Defined in

webgi/src/extras/devices/GyroInputDevice.ts:6


deviceOrientation

Optional deviceOrientation: DeviceOrientationEvent

Defined in

webgi/src/extras/devices/GyroInputDevice.ts:7


permissionMessage

Optional permissionMessage: HTMLDivElement

Defined in

webgi/src/extras/devices/GyroInputDevice.ts:8

Constructors

constructor

new GyroInputDevice(viewer)

Parameters

NameType
viewerViewerApp

Defined in

webgi/src/extras/devices/GyroInputDevice.ts:12