This app was mentioned in 2 comments, with an average of 61.50 upvotes
Hey, I made something very similar using the same tech that Snap chat use. It's seriously interesting stuff.
Here's a quick summary for those who didn't watch. Snap chat use Haar Feature-based Cascade Classifiers for identifying faces. Most people that use the Open CV api are familiar with this method.
This algorithm still runs pretty slow on mobile devices so they rescale the image before running the detector over it.
After which they then use One Millisecond Face Alignment with an Ensemble of Regression Trees to perform the face tracking using the detected regions from step 1. On my app I used 68 points per face - I imagine Snapchat use something similar.
They pass this data to manipulate a candide mesh -- all that's left to do is paint a texture over the mesh!
The app I made doesn't use a candide mesh (never figured out how to implement it) I went for the Moving Least Squares method instead. Turned out ok!
Computer vision takes serious processing power. Snap Chat also (I believe) offload a lot of the processing power to the GPU which is amazing for crunching all that pixel data! It's very fun trying to optimise your code to run on mobile. When I first started I was only getting 4-5fps - but after tinkering a lot I got it up to around 27-30fps on high end devices. Snapchat must have some amazing engineers in their them as they aren't losing resolution or performance when running their algorithm over image data. Even though Snap Chat directly compete with my app, I have to say I am so impressed and blown away by their engineers.
You can check out my app here if you're interested. (It's 100% free) android: https://play.google.com/store/apps/details?id=commanderprompt.facejacker&hl=en_GB ios:https://itunes.apple.com/gb/app/face-jacker./id1110500724?mt=8
I just released this https://play.google.com/store/apps/details?id=commanderprompt.facejacker