MLKitFaceDetection Framework Reference
Stay organized with collections
Save and categorize content based on your preferences.
Type Definitions
The following type definitions are available globally.
-
Declaration
Objective-C
typedef
NSString
*
MLKFaceContourType
-
A block containing an array of faces or nil
if there’s an error.
Declaration
Objective-C
typedef
void
(
^
MLKFaceDetectionCallback
)(
NSArray
<
MLKFace
*>
*
_Nullable
,
NSError
*
_Nullable
)
Parameters
-
@enum FaceDetectorClassificationMode
Classification mode for face detection.
Declaration
Objective-C
typedef
NSInteger
MLKFaceDetectorClassificationMode
-
@enum FaceDetectorPerformanceMode
Performance preference for accuracy or speed of face detection.
Declaration
Objective-C
typedef
NSInteger
MLKFaceDetectorPerformanceMode
-
@enum FaceDetectorLandmarkMode
Landmark detection mode for face detection.
Declaration
Objective-C
typedef
NSInteger
MLKFaceDetectorLandmarkMode
-
@enum FaceDetectorContourMode
Contour detection mode for face detection.
Declaration
Objective-C
typedef
NSInteger
MLKFaceDetectorContourMode
-
Declaration
Objective-C
typedef
NSString
*
MLKFaceLandmarkType
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License
, and code samples are licensed under the Apache 2.0 License
. For details, see the Google Developers Site Policies
. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2024-07-10 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2024-07-10 UTC."],[[["\u003cp\u003eThis documentation details globally available type definitions used for face detection within ML Kit.\u003c/p\u003e\n"],["\u003cp\u003eDefinitions include types for facial contours, landmarks, and detection modes (classification, performance, landmark, contour).\u003c/p\u003e\n"],["\u003cp\u003e\u003ccode\u003eMLKFaceDetectionCallback\u003c/code\u003e is a block providing an array of detected faces or an error.\u003c/p\u003e\n"],["\u003cp\u003eEach type definition provides its Objective-C declaration and a brief description of its purpose.\u003c/p\u003e\n"]]],[],null,["# MLKitFaceDetection Framework Reference\n\nType Definitions\n================\n\nThe following type definitions are available globally.\n- `\n ``\n ``\n `\n\n ### [MLKFaceContourType](#/c:MLKFaceContour.h@T@MLKFaceContourType)\n\n `\n ` \n The facial contours. \n\n #### Declaration\n\n Objective-C \n\n typedef NSString *MLKFaceContourType\n\n- `\n ``\n ``\n `\n\n ### [MLKFaceDetectionCallback](#/c:MLKFaceDetector.h@T@MLKFaceDetectionCallback)\n\n `\n ` \n A block containing an array of faces or `nil` if there's an error. \n\n #### Declaration\n\n Objective-C \n\n typedef void (^MLKFaceDetectionCallback)(NSArray\u003c/ml-kit/reference/ios/mlkitfacedetection/api/reference/Classes/MLKFace *\u003e *_Nullable,\n NSError *_Nullable)\n\n #### Parameters\n\n |---------------|----------------------------------------------------------------------|\n | ` `*faces*` ` | Array of faces detected in the image or `nil` if there was an error. |\n | ` `*error*` ` | The error or `nil`. |\n\n- `\n ``\n ``\n `\n\n ### [MLKFaceDetectorClassificationMode](#/c:MLKFaceDetectorOptions.h@T@MLKFaceDetectorClassificationMode)\n\n `\n ` \n @enum FaceDetectorClassificationMode\n Classification mode for face detection. \n\n #### Declaration\n\n Objective-C \n\n typedef NSInteger MLKFaceDetectorClassificationMode\n\n- `\n ``\n ``\n `\n\n ### [MLKFaceDetectorPerformanceMode](#/c:MLKFaceDetectorOptions.h@T@MLKFaceDetectorPerformanceMode)\n\n `\n ` \n @enum FaceDetectorPerformanceMode\n Performance preference for accuracy or speed of face detection. \n\n #### Declaration\n\n Objective-C \n\n typedef NSInteger MLKFaceDetectorPerformanceMode\n\n- `\n ``\n ``\n `\n\n ### [MLKFaceDetectorLandmarkMode](#/c:MLKFaceDetectorOptions.h@T@MLKFaceDetectorLandmarkMode)\n\n `\n ` \n @enum FaceDetectorLandmarkMode\n Landmark detection mode for face detection. \n\n #### Declaration\n\n Objective-C \n\n typedef NSInteger MLKFaceDetectorLandmarkMode\n\n- `\n ``\n ``\n `\n\n ### [MLKFaceDetectorContourMode](#/c:MLKFaceDetectorOptions.h@T@MLKFaceDetectorContourMode)\n\n `\n ` \n @enum FaceDetectorContourMode\n Contour detection mode for face detection. \n\n #### Declaration\n\n Objective-C \n\n typedef NSInteger MLKFaceDetectorContourMode\n\n- `\n ``\n ``\n `\n\n ### [MLKFaceLandmarkType](#/c:MLKFaceLandmark.h@T@MLKFaceLandmarkType)\n\n `\n ` \n The facial landmarks. \n\n #### Declaration\n\n Objective-C \n\n typedef NSString *MLKFaceLandmarkType"]]