mirror of
https://github.com/cemu-project/DS4Windows.git
synced 2024-12-24 15:41:49 +01:00
Added extra calibration check. Might be useful in some cases where people have reported crashes.
This commit is contained in:
parent
ad7bbe7ea9
commit
6db6315d72
@ -189,7 +189,11 @@ namespace DS4Windows
|
|||||||
calibrationData[5].sensNumer = 2 * SixAxis.ACC_RES_PER_G;
|
calibrationData[5].sensNumer = 2 * SixAxis.ACC_RES_PER_G;
|
||||||
calibrationData[5].sensDenom = accelRange;
|
calibrationData[5].sensDenom = accelRange;
|
||||||
|
|
||||||
calibrationDone = true;
|
// Check that denom will not be zero.
|
||||||
|
calibrationDone = calibrationData[0].sensDenom != 0 &&
|
||||||
|
calibrationData[1].sensDenom != 0 &&
|
||||||
|
calibrationData[2].sensDenom != 0 &&
|
||||||
|
accelRange != 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
private void applyCalibs(ref int yaw, ref int pitch, ref int roll,
|
private void applyCalibs(ref int yaw, ref int pitch, ref int roll,
|
||||||
|
Loading…
Reference in New Issue
Block a user