Questions tagged [cifacefeature]

A CIFaceFeature is a class in Apple's iOS. It describes a face detected in a still or video image.

A CIFaceFeature is a class in Apple's IOS. It describes a face detected in a still or video image. Its properties provide locations for the face’s eyes and mouth. A face object in a video can also have properties that track its location over time—tracking ID and frame count.

Documentation for that class can be found here: CIFaceFeature Reference.

15 questions
14
votes
2 answers

Cut rounded image with the face from CIDetector and CIFaceFeature

How to cut the frame that I receive as faceViewBounds to make a big circle around the face? It's like a badge with the face of the person. Maybe I should get the center of faceViewBounds then I have to find this center in theImageView.image and draw…
Bogdan Bogdanov
  • 882
  • 11
  • 36
  • 79
6
votes
1 answer

Swift - Add carnival mask to a photo which contains face

I have photo with face on it. I have carnival mask: With this function I detect the face: let ciImage = CIImage(cgImage: photo) let options = [CIDetectorAccuracy: CIDetectorAccuracyHigh] let faceDetector = CIDetector(ofType:…
Bogdan Bogdanov
  • 882
  • 11
  • 36
  • 79
6
votes
4 answers

CIDetector and UIImagePickerController

I'm trying to implement the built-in iOS 5 face detection API. I'm using an instance of UIImagePickerController to allow the user to take a photo and then I'm trying to use CIDetector to detect facial features. Unfortunately, featuresInImage always…
tonyc
  • 832
  • 2
  • 11
  • 23
5
votes
0 answers

AVCaptureVideoPreviewLayer issues with Video Gravity and Face Detection Accuracy

I want to use AVFoundation to set up my own camera feed and process the live feed to detect smiles. A lot of what I need has been done here: https://developer.apple.com/library/ios/samplecode/SquareCam/Introduction/Intro.html This code was written…
4
votes
2 answers

Transforming CGPoint results returned from CIFaceFeature

I am trying to figure out how to transform the CGPoint results returned from CIFaceFeature in order to draw with them in a CALayer. Previously I had normalized my image to have 0 rotation in order to make things easier but that causes problems for…
spring
  • 18,009
  • 15
  • 80
  • 160
3
votes
1 answer

How can I detect complete body like hand , leg?

Using CIFaceFeature we can detect face feature. But I want to detect hand and leg too. How can we detect these? Is there any other classes or logic using which we can detect these.
Rajneesh071
  • 30,846
  • 15
  • 61
  • 74
3
votes
2 answers

iOS face detector orientation and setting of CIImage orientation

EDIT found this code that helped with front camera images http://blog.logichigh.com/2008/06/05/uiimage-fix/ Hope others have had a similar issue and can help me out. Haven't found a solution yet. (It may seem a bit long but just a bunch of helper…
Avba
  • 14,822
  • 20
  • 92
  • 192
2
votes
1 answer

How to Find position of Ears, cheek and Head positon for IOS using CIFaceFeature

In my project I need to fine all parts of faces like eyes, mouth, nose, ears, cheek and head. By using CIFaceFeature, I can get Eyes position and Mouth Position. How to find rest of parts position?
Varadharaj
  • 23
  • 3
1
vote
0 answers

Transform an Image using CIFaceFeature in iOS

I use CIDetector and CIFaceFeature to detect face on the front facing camera. Also trying to place a hat on the head. The hat is placing fine when the head is straight. If I tilt my head the hat goes small and goes away from head. Code use to add…
Maniganda saravanan
  • 2,188
  • 1
  • 19
  • 35
1
vote
1 answer

Output wrong eye position using CIfacefeature and SquareCam

I am trying to write code which put a sticker on eyes and the code is based on SquareCam. It detects faces well, but when I tried to output my image on left eye, it always gives wrong position even though I used the same ways on finding face…
CJ KIM
  • 13
  • 2
1
vote
0 answers

How to use CIDetector and CIFaceFeature with large images and different aspect ratios

I've been working on this for days and all examples out there are if the image size is the same as the UIImageView. In addition, a lot of the answered on Stack are outdated. I have an app where the user can add an image, which can be of any size,…
Tal Zion
  • 6,308
  • 3
  • 50
  • 73
1
vote
1 answer

Using CIFaceFeature detection, can I determine the Confidence of the Face detected in an Image

I'm just starting to take a look at CIDetector to detect faces in an image but am wondering whether anyone has had any luck determining the confidence level that the detector has when it detected the face. I know we can essentially set the detector…
Mustafa Shabib
  • 798
  • 12
  • 35
0
votes
1 answer

Converting CIImage coordinates to CGRect from CIFaceFeature

I am trying to place a square rectangle over a user's face which I am recognizing using CIFaceFeature in real time over a full screen (self.view.frame) video feed. However, the coordinates I am getting from CIFaceFeature.bounds are from a different…
Anters Bear
  • 1,816
  • 1
  • 15
  • 41
0
votes
1 answer

CIFaceDetector origin inaccuracy

I'm trying to use CIDetector/CIFaceDetector for basic face detection, and, while it seems to recognize faces correctly, the bounds rectangle is consistently inaccurate in everything I throw at it. Here's a sample, with the bounds it detects as a…
puzzl
  • 833
  • 9
  • 19
0
votes
1 answer

Memory usage of face detector not released

I'm using the iOS face detector on all possible orientations of an image like this for (exif = 1; exif <= 8 ; exif++) { @autoreleasepool { NSNumber *orientation = [NSNumber numberWithInt:exif]; NSDictionary *imageOptions =…
Avba
  • 14,822
  • 20
  • 92
  • 192