-
Notifications
You must be signed in to change notification settings - Fork 2.6k
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
Rotation bugfix. #982
base: master
Are you sure you want to change the base?
Rotation bugfix. #982
Conversation
As this is a reversal of atsar@287720a I'd like more info on what the perceived bug is. |
The getRotation function returns the change of the angle since the rotation start. When you land two fingers on the screen, it gives start[0] and start[1] points that determine the orientation relative to the screen. Then, when you move them, it gives end[0] and end[1] - new current finger locations. So, the rotation is the difference (minus) between the end orientation and the start orientation. If you put plus there, it simply gives incorrect number. |
@runspired the logic in this PR is correct let me explain. the formula to get the angle relative to the screen for 2 points is No lets take the very simple case of our starting points being at No we move the second point to This can also be confirmed in the negative or counterclockwise direction. Again starting at Where the current formula fails to work is in a non zero case. take starting points of |
I would like to get this merged @arschmitz I think it resolves the 90deg jump issue. |
@runspired sounds good to me based on my comment above i think this is completely correct we just need to get the conflict resolved |
whats the status on this merge ? |
@arschmitz hey there! Almost a year has passed. Can it be merged? Need it resolved. |
@arschmitz is this project dead? |
I had big problems with the pinch and rotate example on the webiste. No solution really worked. |
This has been applied in proposed 2.1.0: squadette#1 @arschmitz, thank you for the detailed explanation. |
Any chance to merge this fix if we open a pr with conflict solved? |
No description provided.