How can I do facial recognition on the iPhone. Could someone provide me with references/articles to point me in the right direction please? I have done research and realised
As you pointed out, the first step (detection of the face) is easy with iOS 5 and CoreImage.framework. Quick example:
CIImage *image = [CIImage imageWithCGImage:image_ref];
NSDictionary *options = [NSDictionary dictionaryWithObject:CIDetectorAccuracyHigh forKey:CIDetectorAccuracy];
CIDetector *detector = [CIDetector detectorOfType:CIDetectorTypeFace context:nil options:options];
NSArray *features = [detector featuresInImage:image];
for (CIFaceFeature *feature in features)
{
CGRect face_bounds = [feature bounds];
CGPoint mouth_position = [feature mouthPosition];
// do something with these values
}
With regards to the second part of your question (i.e. facial recognition), I shall leave that to someone more qualified than myself to answer. :)