Removed MotionInput Calibration (#4705)
Don't know why this is here. It just seems to set the filter to an identity. Which then quickly returns to where its supposed to be anyways.
This commit is contained in:
parent
add2a9d151
commit
e27f5522e2
@ -12,7 +12,6 @@ namespace Ryujinx.Input
|
|||||||
public Vector3 Rotation { get; set; }
|
public Vector3 Rotation { get; set; }
|
||||||
|
|
||||||
private readonly MotionSensorFilter _filter;
|
private readonly MotionSensorFilter _filter;
|
||||||
private int _calibrationFrame = 0;
|
|
||||||
|
|
||||||
public MotionInput()
|
public MotionInput()
|
||||||
{
|
{
|
||||||
@ -29,26 +28,6 @@ namespace Ryujinx.Input
|
|||||||
{
|
{
|
||||||
if (TimeStamp != 0)
|
if (TimeStamp != 0)
|
||||||
{
|
{
|
||||||
if (gyro.Length() <= 1f && accel.Length() >= 0.8f && accel.Z >= 0.8f)
|
|
||||||
{
|
|
||||||
_calibrationFrame++;
|
|
||||||
|
|
||||||
if (_calibrationFrame >= 90)
|
|
||||||
{
|
|
||||||
gyro = Vector3.Zero;
|
|
||||||
|
|
||||||
Rotation = Vector3.Zero;
|
|
||||||
|
|
||||||
_filter.Reset();
|
|
||||||
|
|
||||||
_calibrationFrame = 0;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
_calibrationFrame = 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
Accelerometer = -accel;
|
Accelerometer = -accel;
|
||||||
|
|
||||||
if (gyro.Length() < deadzone)
|
if (gyro.Length() < deadzone)
|
||||||
|
Loading…
Reference in New Issue
Block a user