Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

ios animation like emailing photo

I'm really curious as to how apple does this transition: If you go to a photo within the photos app, then try to send it in an email, you'll see this pretty cool transition where Apple grabs the image, slides up a modal email vc, then places the image into the message. Pretty cool.

Anyway, im wondering if anyone has any ideas as to how to do something like that. One way I'm thinking about doing it is to actually reproduce it, stick it on the UIWindow, then animate it that way. I'm actually kind of stumped as to how this could work. Any thoughts??

like image 854
Sean Danzeiser Avatar asked Aug 09 '12 04:08

Sean Danzeiser


1 Answers

I actually got pretty close tonight with this (sample project up on Github). It's a bit "Fake it to make it", but then again, so is the Photos app if you really watch the animation closely. The values for the animation are hard coded in, but it's mostly for scale and move, which means this should work with pretty much any image (don't quote me on that). The code is iOS 5+ for now because Xcode keeps yelling at me about deprecated modal presentation methods...

like image 84
CodaFi Avatar answered Oct 02 '22 17:10

CodaFi