Removed SDL_stdinc.h dependency on HAVE_M_PI, added SDL_M_PIl (double) and SDL_M_PIf (float) instead

This commit is contained in:
Sam Lantinga
2022-11-25 10:33:37 -08:00
parent 8733927e35
commit 670f1df469
16 changed files with 38 additions and 44 deletions

View File

@@ -612,7 +612,7 @@ HIDAPI_DriverPS5_ApplyCalibrationData(SDL_DriverPS5_Context *ctx, int index, Sin
/* Convert the raw data to the units expected by SDL */
if (index < 3) {
result = (result / GYRO_RES_PER_DEGREE) * (float)M_PI / 180.0f;
result = (result / GYRO_RES_PER_DEGREE) * SDL_M_PIf / 180.0f;
} else {
result = (result / ACCEL_RES_PER_G) * SDL_STANDARD_GRAVITY;
}