I’d really appreciate some advice from you guys. I am trying to process a gyroscope input and map it to my game, i.e. player tilts their device and the character on screen moves left and right.
Essentially, I have it working. The following two scenarios occur in my game, as desired. You can see that the player is standing still, facing one direction. When they yaw their device (blue rectangle) around its local y-axis (going from the top of the screen down towards gravity), I am able to correctly process the input and move the character on-screen. Great!

BUT! I have a problem. Let’s consider Scenario 3 below:

Here, the player is technically not yawing their device. They are moving their physical body position in world space. You can see that whilst the device has moved 45° globally, it is still facing the player face-on. This should not be registered in the game and it should be ignored by the character. I am really struggling to achieve this.
Right now, I see no way of distinguishing the global rotation from the local rotation, and then ignoring it. The result is unpredictable and undesirable movement. Let’s say if the player was sat in a rotating chair and turning their body slightly whilst playing, the game misinterprets this and turns the character. I need to prevent this from happening. Does anyone have any advice on how to achieve this?
Notes: I am using Unity 2020.3 and the standard UnityEngine.Input class (not the new Input Manager). I also have deliberately avoided showing code, because the code to get this far is extensive. I am using the Gyro exclusively so far and nothing from the accelerometer. I can show code if needed, but first I thought it might be better to just hear advice.
