I'm trying to get a similar effect to the one described in the pictures. The white area on the left isn't on the original photo, it pushes the pixels away. I've tried using Core Image (which offered a few close effects to this) but it was too slow for my needs. I need the effect to be snappy so I can make it responsive to touch.
Is there a close effect \ animation in the iOS sdk that does something similar to this with a UIVIew? ( I couldn't find anything close) If not, can someone offer how to attack this using OpenGL? (code examples are more than welcome)
(This effect will take an important roll in an open source class I'm writing so I'd prefer not to use a 3rd party class such as GPUImage if a simpler solution is available (I'm targeting this class to be dependencies free))
Another thing you might look at is the Core Image hole distortion filter (CIHoleDistortion) that was added in iOS 6. It creates an effect rather like what you're looking for. Here is a sample image generated from a test program I wrote that gets pretty close.
However, you'll notice that Apple's filter causes the image to "pull away" from the edges of the frame. I think this is a bug, but good luck getting Apple to fix it:
There's a new great open source class that answers my question completely with a magnificent example. You can find it here.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With