-
-
Notifications
You must be signed in to change notification settings - Fork 367
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
start of adding touch input #1898
base: main
Are you sure you want to change the base?
Conversation
Where? |
Thanks |
/// <summary> | ||
/// The last known normalized position of the finger. | ||
/// </summary> | ||
public Vector2 NormalizedPosition { get; } | ||
|
||
/// <summary> | ||
/// The last known speed of the finger. | ||
/// </summary> | ||
public Vector2 Speed { get; } | ||
|
||
/// <summary> | ||
/// The last known normalized speed of the finger. | ||
/// </summary> | ||
public Vector2 NormalizedSpeed { get; } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could there be some documentation in here about what normalized means in this specific context? In the case of graphics programming this could very well mean -1 -> 1
or 0 -> 1
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I added (0..1) and (-1..1). Is this enough? In general positions are normalized to range 0 to 1 and speed values to range -1 to 1 as they have a direction. I tried to add this information everywhere before but forgot it here I guess.
Summary of the PR
This adds touch devices to the input abstraction. The goal is to add touch gesture recognition to the SDL backend to enable touch gestures and simple touch finger events on Android and iOS.
Related issues, Discord discussions, or proposals
I proposed this a long time ago and finally found some time for it.