Class LinearAccelerationSensor
Input device representing linear acceleration affecting the device playing the content.
Inherited Members
Namespace: UnityEngine.InputSystem
Syntax
public class LinearAccelerationSensor : Sensor
Remarks
An accelerometer let's you measure the acceleration of a device, and can be useful to control content by moving a device around. Linear acceleration is the acceleration of a device unaffected by gravity forces. This is usually derived from a hardware Accelerometer, by subtracting the effect of gravity (see GravitySensor).
Properties
acceleration
Declaration
public Vector3Control acceleration { get; }
Property Value
Type | Description |
---|---|
Vector3Control |
current
Declaration
public static LinearAccelerationSensor current { get; }
Property Value
Type | Description |
---|---|
LinearAccelerationSensor |
Methods
FinishSetup()
Declaration
protected override void FinishSetup()
Overrides
MakeCurrent()
Declaration
public override void MakeCurrent()
Overrides
OnRemoved()
Declaration
protected override void OnRemoved()