menu
GamepadMotion
import { GamepadMotion } from "destack:input/binding";
Gamepad motion state snapshot.
1export struct GamepadMotion {2 timestampNs: uint64;3 accelerationX: float64;4 accelerationY: float64;5 accelerationZ: float64;6 gravityX: float64;7 gravityY: float64;8 gravityZ: float64;9 gyroscopeX: float64;10 gyroscopeY: float64;11 gyroscopeZ: float64;12}Members
timestampNs: uint64Monotonic update timestamp in nanoseconds.
accelerationX: float64Linear acceleration x component in meters per second squared.
accelerationY: float64Linear acceleration y component in meters per second squared.
accelerationZ: float64Linear acceleration z component in meters per second squared.
gravityX: float64Gravity x component in meters per second squared when available.
gravityY: float64Gravity y component in meters per second squared when available.
gravityZ: float64Gravity z component in meters per second squared when available.
gyroscopeX: float64Rotation rate around x in radians per second.
gyroscopeY: float64Rotation rate around y in radians per second.
gyroscopeZ: float64Rotation rate around z in radians per second.