How does one implement pinch gestures on the iPhone? I\'m familiar with using touch events on the iPhone but I\'m extremely lazy and don\'t want to re-invent the wheel for somet
If you're looking for a simple code example of the pinch gesture, I use the method described by Brock in the example application I describe here (in the second-to-last and last versions of the application on that page). The pinch gestures are used to scale a couple of Core Animation layers in that example.
All he's describing as far as the distance calculation is simply the Pythagorean Theorem applied between two points (with the X and Y distances as the two faces of a right triangle).