Qt4 Touch and Rotate
May 7, 2009 Matteo Bertozzi | Filed Under Qt4 | No CommentsAlan has asked my How I’ve implemented the Touch and Rotate feature of the Moko. The answer is very simple, It’s all Magic! There’re very few lines of code to do it, because all the magic is made by atan2.
Atan2 is a variation of the arctangent function. For any real arguments x and y not both equal to zero, atan2(y, x) is the angle in radians between the positive x-axis of a plane and the point given by the coordinates (x, y) on it.
The Source Code is available here: Qt4 Touch and Rotate Source Code.
OT: PyCon3 (Italia) starts Tomorrow!
