mirror of
https://github.com/Ryujinx/SDL.git
synced 2025-01-09 01:15:26 +00:00
Fixed gyro values for the Armor-X Pro controller
(cherry picked from commit 8df7b4d8539338121b1e34e29f331b28f1f4ff05)
This commit is contained in:
parent
d043c8535b
commit
0bf63175ab
|
@ -605,13 +605,15 @@ static void HIDAPI_DriverPS4_LoadCalibrationData(SDL_HIDAPI_Device *device)
|
||||||
|
|
||||||
if (device->vendor_id == USB_VENDOR_SONY &&
|
if (device->vendor_id == USB_VENDOR_SONY &&
|
||||||
device->product_id == USB_PRODUCT_SONY_DS4_STRIKEPAD) {
|
device->product_id == USB_PRODUCT_SONY_DS4_STRIKEPAD) {
|
||||||
/* The Armor-X Pro seems to rotate in the opposite direction on the Z axis */
|
/* The Armor-X Pro seems to only deliver half the rotation it should,
|
||||||
|
* and in the opposite direction on the Z axis */
|
||||||
switch (i) {
|
switch (i) {
|
||||||
case 0:
|
case 0:
|
||||||
case 1:
|
case 1:
|
||||||
|
scale *= 2.0;
|
||||||
break;
|
break;
|
||||||
case 2:
|
case 2:
|
||||||
scale *= -1.0;
|
scale *= -2.0;
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
|
|
Loading…
Reference in a new issue