Customization using Fragment
By default, FaceSDK provides the ability to inheritance from FaceDefaultUiFragment or FaceUiFragment. Any child class must be registered in Configuration using the registerUiFragmentClass method. See example:

Liveness

Java
Kotlin
1
LivenessConfiguration configuration = new LivenessConfiguration.Builder()
2
.registerUiFragmentClass(BasicCustomUiFragment.class) // BasicCustomUiFragment - custom fragment
3
.build();
4
FaceSDK.Instance().startLiveness(context, configuration, livenessResponse -> {});
Copied!
1
Copied!

Face Capture

Java
Kotlin
1
FaceCaptureConfiguration configuration = new FaceCaptureConfiguration.Builder()
2
.registerUiFragmentClass(BasicCustomUiFragment.class) // BasicCustomUiFragment - custom fragment
3
.build();
4
FaceSDK.Instance().presentFaceCaptureActivity(context, configuration, faceCaptureResponse -> { });
Copied!
1
Copied!
Last modified 2mo ago
Copy link