From e2c3ae8e4461cbdfd3757304c75b41b6c551dc2e Mon Sep 17 00:00:00 2001 From: Narr the Reg Date: Mon, 3 May 2021 08:59:37 -0500 Subject: [PATCH] hid: Correct some gesture errors I recently did some RE on touch gestures with the help of a nro I made. I have found that those values where incorrect. --- nx/include/switch/services/hid.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/nx/include/switch/services/hid.h b/nx/include/switch/services/hid.h index 9577377a..21b3ac90 100644 --- a/nx/include/switch/services/hid.h +++ b/nx/include/switch/services/hid.h @@ -328,8 +328,8 @@ typedef enum { /// HidGestureAttribute typedef enum { - HidGestureAttribute_IsNewTouch = BIT(0), ///< IsNewTouch - HidGestureAttribute_IsDoubleTap = BIT(1), ///< IsDoubleTap + HidGestureAttribute_IsNewTouch = BIT(4), ///< IsNewTouch + HidGestureAttribute_IsDoubleTap = BIT(8), ///< IsDoubleTap } HidGestureAttribute; /// HidGestureDirection @@ -1012,8 +1012,8 @@ typedef struct HidGestureState { float velocity_x; ///< VelocityX float velocity_y; ///< VelocityY u32 attributes; ///< Bitfield of \ref HidGestureAttribute. - u32 scale; ///< Scale - u32 rotation_angle; ///< RotationAngle + float scale; ///< Scale + float rotation_angle; ///< RotationAngle s32 point_count; ///< Number of entries in the points array. HidGesturePoint points[4]; ///< Array of \ref HidGesturePoint with the above count. } HidGestureState;