iOS
Faceplugin Face Recognition iOS SDK. Fully on-premise face matching, 1:N identify, and 2D liveness. Xcode frameworks, setActivation, initSDK, detectImage, VideoWorker.
Fully on-premise Face Recognition SDK for iOS. Detect faces, extract templates, match 1:1 or live 1:N, and check passive 2D liveness on the device.
Native class: FaceRecognitionSDK (facerecognitionsdk.framework). Status codes: 0 Success, 1 Invalid license, 2 Expired, 3 Not activated, 4 Init failed.
Code
Setup
Unzip the frameworks from Google Drive next to the Xcode project:
facerecognitionsdk.framework,FaceRecognitionEngine.framework,onnxruntime.framework.Add the SDK frameworks to the project in Xcode (Embed & Sign).
Add
FaceRecognitionSDK-Bridging-Header.hto Build Settings (#import <facerecognitionsdk/FaceRecognitionSDK.h>).Set your Signing Team. Demo bundle id:
com.faceplugin.facerecognitionsdk.app. Physical iPhone, iOS 13+. Call setActivation → initSDK off the main thread.
APIs
setActivation: This API is used to activate the SDK
Input
license (NSString*): The license string (
license key)
Return value
The SDK activation status code.
0: Success
1: Invalid license
2: Expired
3: Not activated
4: Init failed
initSDK: This API is used to initialize the SDK
Input
None
Return value
The SDK initialization status code.
0: Success
1–4: see
setActivation
getMachineCode: This API is used to retrieve the machine code
getLicenseStatus: This API is used to read license status
detectImage: This API is used to detect faces and return engine JSON
Input
image (UIImage*): The input image
flags: Estimators to run (
FaceRecognitionDetectAll,DetectLiveness, …)
Return value
JSON string (Linux-compatible, same idea as HTTP POST /api/detect).
qualityImage: This API is used to run face image quality checks
matchImage1: This API is used to compare two photos (1:1)
extractFeatureFromImage: This API is used to extract a face template
Input
A face image (typically cropped).
Return value
JSON with the template. Store the feature bytes in your database.
similarityWithFeature1: This API is used to calculate the similarity between two face templates
Input
Two template blobs from extractFeatureFromImage.
Return value
Similarity 0.0–1.0, or -1 on error. Demo Identify default threshold is 0.67.
setLandmarkMode: This API is used to set the landmark model
VideoWorker: This API is used for live 1:N identify
deinitSDK: This API is used to unload the engine
Run the demo
Place the three frameworks next to the Xcode project (see Setup).
Keep demo bundle id
com.faceplugin.facerecognitionsdk.app.Run on a physical iPhone (iOS 13+).
Wait until the home status bar shows Ready. Then Enroll / Identify / Capture / Attribute unlock.
Call setActivation → initSDK off the main thread. The engine is not concurrent.
Screenshots
The gallery is Android sample UI from faceplugin-assets. iOS demo tiles match these screens; there is no separate iOS photoshoot in these docs.



License
Licenses are offline. The sample key is only for the demo bundle. Request a new license key if you change the demo bundle.
Identify default threshold is 0.67. Liveness demo default is 0.5.
Integrate into your own app
You need the three frameworks and FaceRecognitionSDK. You do not need the demo view controllers.
Typical call order: setActivation → initSDK → detectImage / extractFeatureFromImage → store templates in your database → similarityWithFeature1:feature2: or VideoWorker for live 1:N.
Public header only: detectImage, extractFeatureFromImage, similarityWithFeature1:feature2:, VideoWorker. There is no Objective-C faceDetection: returning FaceBox on this framework.
Request a License & Support · Contact us
FAQ
What APIs does this page ship? Swift equivalents of setActivation, init, face detection, template extract, similarity, and VideoWorker Identify.
Are the screenshots iOS? No. The gallery uses Android sample UI. iOS demo tiles match those screens.
Offline? Yes, after license key for the demo bundle id (or yours).
Related documentation
Last updated