Hi all!
Does anyone know of a really good pinch-zooming algorithm? This is trickier than I had imagined, as you have to scale -AND- translate to keep the pinch zooming centered between your fingers.
In my project I'm using sprite scaling, rather than viewport scaling. Imagine that I had a scene with two square sprites, placed a small distance apart. Using pinch-zoom I want to be able to zoom in and out smoothly with the zoom centering where the pinch began on the screen. So if I place my fingers on the left-hand sprite and spread them apart, the zoom should happen over the left sprite.
I've noticed that there are a couple of algorithms on here already, but none of them appear to perform the zoom like this... Anyone have anything in their own projects that they're using to accomplish this?