FirebaseMLVision Framework Reference

FIRVisionFace


@interface FIRVisionFace : NSObject

A human face detected in an image.

  • The rectangle that holds the discovered relative to the detected image in the view coordinate system.

    Declaration

    Objective-C

    @property (nonatomic, readonly) CGRect frame;
  • Indicates whether the face has a tracking ID.

    Declaration

    Objective-C

    @property (nonatomic, readonly) BOOL hasTrackingID;
  • The tracking identifier of the face.

    Declaration

    Objective-C

    @property (nonatomic, readonly) NSInteger trackingID;
  • Indicates whether the detector found the head y euler angle.

    Declaration

    Objective-C

    @property (nonatomic, readonly) BOOL hasHeadEulerAngleY;
  • Indicates the rotation of the face about the vertical axis of the image. Positive y euler angle is when the face is turned towards the right side of the image that is being processed.

    Declaration

    Objective-C

    @property (nonatomic, readonly) CGFloat headEulerAngleY;
  • Indicates whether the detector found the head z euler angle.

    Declaration

    Objective-C

    @property (nonatomic, readonly) BOOL hasHeadEulerAngleZ;
  • Indicates the rotation of the face about the axis pointing out of the image. Positive z euler angle is a counter-clockwise rotation within the image plane.

    Declaration

    Objective-C

    @property (nonatomic, readonly) CGFloat headEulerAngleZ;
  • Indicates whether a smiling probability is available.

    Declaration

    Objective-C

    @property (nonatomic, readonly) BOOL hasSmilingProbability;
  • Probability that the face is smiling.

    Declaration

    Objective-C

    @property (nonatomic, readonly) CGFloat smilingProbability;
  • Indicates whether a left eye open probability is available.

    Declaration

    Objective-C

    @property (nonatomic, readonly) BOOL hasLeftEyeOpenProbability;
  • Probability that the face’s left eye is open.

    Declaration

    Objective-C

    @property (nonatomic, readonly) CGFloat leftEyeOpenProbability;
  • Indicates whether a right eye open probability is available.

    Declaration

    Objective-C

    @property (nonatomic, readonly) BOOL hasRightEyeOpenProbability;
  • Probability that the face’s right eye is open.

    Declaration

    Objective-C

    @property (nonatomic, readonly) CGFloat rightEyeOpenProbability;
  • Unavailable.

    Declaration

    Objective-C

    - (nonnull instancetype)init;
  • Returns the landmark, if any, of the given type in this detected face.

    Declaration

    Objective-C

    - (nullable FIRVisionFaceLandmark *)landmarkOfType:
        (nonnull FIRFaceLandmarkType)type;

    Parameters

    type

    The type of the facial landmark.

    Return Value

    The landmark of the given type in this face. nil if there isn’t one.

  • Returns the contour, if any, of the given type in this detected face.

    Declaration

    Objective-C

    - (nullable FIRVisionFaceContour *)contourOfType:
        (nonnull FIRFaceContourType)type;

    Parameters

    type

    The type of the facial contour.

    Return Value

    The contour of the given type in this face. nil if there isn’t one.