Class Accelerometer
Accelerometer data of the acceleration of the device in three dimensional space.
Implements
Inherited Members
Namespace: Evergine.Platform
Assembly: Evergine.Platform.dll
Syntax
public class Accelerometer : IDisposable
Properties
Acceleration
Gets the acceleration vector in G's (gravitational force).
Declaration
public Vector3 Acceleration { get; }
Property Value
Type | Description |
---|---|
Vector3 |
Remarks
The coordinate-system is defined relative to the screen of the device in its default orientation. The axes are not swapped when the device's screen orientation changes. The X axis is horizontal and points to the left, the Y axis is vertical and points up and the Z axis points towards the outside of the back face of the screen. In this system, coordinates behind the screen have positive Z values.
IsStarted
Gets a value indicating whether the accelerometer sensor has been started.
Declaration
public bool IsStarted { get; }
Property Value
Type | Description |
---|---|
bool |
Methods
Dispose()
Declaration
public void Dispose()
Start()
Start monitoring for changes to accelerometer.
Declaration
public void Start()
Stop()
Stop monitoring for changes to accelerometer.
Declaration
public void Stop()