mirror of
https://github.com/libretro/RetroArch
synced 2025-02-07 03:40:24 +00:00
Fix radial analog deadzone scaling
This commit is contained in:
parent
18d3eba614
commit
42d02565af
@ -13962,7 +13962,7 @@ static int16_t input_joypad_axis(const input_device_driver_t *drv,
|
||||
/* due to the way normal_mag is calculated differently for buttons and
|
||||
* sticks, this results in either a radial scaled deadzone for sticks
|
||||
* or linear scaled deadzone for analog buttons */
|
||||
val = val * MIN(1.0f,((normal_mag - input_analog_deadzone)
|
||||
val = val * MAX(1.0f,(1.0f / normal_mag)) * MIN(1.0f,((normal_mag - input_analog_deadzone)
|
||||
/ (1.0f - input_analog_deadzone)));
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user