TopDown Engine v5.0
Loading...
Searching...
No Matches
MoreMountains.Tools.MMGyroParallax Class Reference

Add this class to a camera rig (an empty object), bind some Cinemachine virtual cameras to it, and they'll move around the specified object as your gyro powered device moves. More...

Inheritance diagram for MoreMountains.Tools.MMGyroParallax:
MoreMountains.Tools.MMGyroscope

Public Attributes

List< MMGyroCamCams
 the list of cameras to move as the gyro moves
Public Attributes inherited from MoreMountains.Tools.MMGyroscope
bool _TestMode = false
 turn this on if you want to use the inspector to test this camera
float TestXAcceleration = 0f
 the rotation to apply on the x axiswhen in test mode
float TestYAcceleration = 0f
 the rotation to apply on the y axis while in test mode
float TestZAcceleration = 0f
 the rotation to apply on the y axis while in test mode
bool CalibrateButton
bool GyroscopeInitializationBtn

Protected Attributes

Vector3 _newAngles

Additional Inherited Members

Public Types inherited from MoreMountains.Tools.MMGyroscope
enum  TimeScales { Scaled , Unscaled }
Public Member Functions inherited from MoreMountains.Tools.MMGyroscope
virtual void CalibrateDebug ()
virtual void GyroscopeDebugInitialization ()
Static Public Member Functions inherited from MoreMountains.Tools.MMGyroscope
static void GyroscopeInitialization ()
static void GetValues ()
Static Public Attributes inherited from MoreMountains.Tools.MMGyroscope
static bool GyroscopeActive = true
 whether or not the gyroscope is active
static TimeScales TimeScale = TimeScales.Scaled
 the timescale to use (scaled or unscaled)
static Vector2 Clamps = new Vector2(-1f, 1f)
 the min/max clamp values applied to all acceleration and gravity vectors
static float LerpSpeed = 1f
 the speed at which lerped values move towards their targets
static bool TestMode
 whether or not to use test values instead of real sensor data
Protected Member Functions inherited from MoreMountains.Tools.MMGyroscope
virtual void OnEnable ()
virtual void OnDisable ()
virtual void Start ()
virtual void Update ()
virtual void HandleTestMode ()
Static Protected Member Functions inherited from MoreMountains.Tools.MMGyroscope
static Quaternion GyroscopeToUnity (Quaternion q)
Static Protected Attributes inherited from MoreMountains.Tools.MMGyroscope
static Vector3 _testVector = Vector3.zero
Properties inherited from MoreMountains.Tools.MMGyroscope
static Quaternion GyroscopeAttitude [get]
 the current device orientation as a quaternion (from AttitudeSensor / Input.gyro.attitude)
static Vector3 GyroscopeRotationRate [get]
 the current unbiased rotation rate in radians per second around each axis (from Gyroscope / Input.gyro.rotationRateUnbiased)
static Vector3 GyroscopeAcceleration [get]
 the current user-induced acceleration (gravity removed) in g-force units (from LinearAccelerationSensor / Input.gyro.userAcceleration)
static Vector3 InputAcceleration [get]
 the current raw accelerometer reading including gravity, clamped to the Clamps range (from Accelerometer / Input.acceleration)
static Vector3 GyroscopeGravity [get]
 the current gravity vector as reported by the sensor, clamped to the Clamps range (from GravitySensor / Input.gyro.gravity)
static Quaternion InitialGyroscopeAttitude [get]
 the device orientation captured at auto-calibration time (~0.5 s after start)
static Vector3 InitialGyroscopeRotationRate [get]
 the rotation rate captured at auto-calibration time
static Vector3 InitialGyroscopeAcceleration [get]
 the user acceleration captured at auto-calibration time
static Vector3 InitialInputAcceleration [get]
 the raw accelerometer reading captured at auto-calibration time
static Vector3 InitialGyroscopeGravity [get]
 the gravity vector captured at auto-calibration time
static Vector3 CalibratedInputAcceleration [get]
 the raw accelerometer reading rotated into the calibration reference frame
static Vector3 CalibratedGyroscopeGravity [get]
 the gravity vector rotated into the calibration reference frame
static Vector3 LerpedCalibratedInputAcceleration [get]
 CalibratedInputAcceleration smoothed over time using LerpSpeed.
static Vector3 LerpedCalibratedGyroscopeGravity [get]
 CalibratedGyroscopeGravity smoothed over time using LerpSpeed.

Detailed Description

Add this class to a camera rig (an empty object), bind some Cinemachine virtual cameras to it, and they'll move around the specified object as your gyro powered device moves.

Member Data Documentation

◆ _newAngles

Vector3 MoreMountains.Tools.MMGyroParallax._newAngles
protected

◆ Cams

List<MMGyroCam> MoreMountains.Tools.MMGyroParallax.Cams

the list of cameras to move as the gyro moves


The documentation for this class was generated from the following file:
  • H:/Code/MoreMountains/topdownengine/Assets/TopDownEngine/ThirdParty/MoreMountains/MMTools/Accessories/MMCinemachine/MMGyroParallax/MMGyroParallax.cs