PDA

View Full Version : Doing a (simple?) 2D Image Background effect




Soulstorm
May 14, 2009, 04:41 PM
I am trying to make an application as proof of concept. I have an image, with which I want to fill the screen. When the user clicks somewhere, I want the image to be distorted in that spot, like if it was on a net of some short (that spot of the image going forwards and backwards).

Does anyone have any idea on how to make this possible?



jnic
May 15, 2009, 07:39 AM
For simple animations, CGAffineTransform (http://developer.apple.com/iPhone/library/documentation/GraphicsImaging/Reference/CGAffineTransform/Reference/reference.html) and a bit of matrix algebra should do the trick. Depending on the sort of thing you're going for, OpenGL ES might be a better option though.