Try to fix broken gyroscope control in iOS
This commit is contained in:
parent
1b3cc83235
commit
1e5e91dabf
@ -559,6 +559,8 @@ namespace irr
|
||||
ev.AccelerometerEvent.Z = motionManager.accelerometerData.acceleration.z * 9.81;
|
||||
if (m_upside_down)
|
||||
ev.AccelerometerEvent.Y = -ev.AccelerometerEvent.Y;
|
||||
if (ev.AccelerometerEvent.X < 0.0)
|
||||
ev.AccelerometerEvent.X *= -1.0;
|
||||
postEventFromUser(ev);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user