Passive Face Capture Activity
This activity is used to scan the user's face using a Passive Face Capture Session.
Properties
The future for the camera provider
The capture analyzer. This processes the frames from the camera
Intent extra to indicate that liveness check is required
Intent extra for password
Intent extra for QR code data
Intent extra to indicate that just the image bytes should be returned
The frame layout showing the pinch to zoom animation
The Oval overlay view to show the face oval where the user is supposed to align their face
Whether the pinch to zoom hint has been shown (it is only shown once)
The preview view for the camera
The text view to show instructions to the user
Functions
This method is used to bind the camera preview and make the capture analyzer process the frames from the camera. When called, this method will also create a new session and reset the UI. Any exception from the SDK will be caught and shown in the UI.
Called liveness check after the face capture session is complete
The future for the camera provider
The capture analyzer. This processes the frames from the camera
The frame layout showing the pinch to zoom animation
The Oval overlay view to show the face oval where the user is supposed to align their face
The preview view for the camera
Passive Face Capture Session
The text view to show instructions to the user
This method is used to hide the pinch to zoom hint.
Whether the pinch to zoom hint has been shown (it is only shown once)
Move to the next activity when the face capture session is complete
This method is used to notify the listener that the first frame has been captured.
Called when there is an error while processing a frame
This method is used to process the pose of the user's face based on the current frame.
Reset the session
The future for the camera provider
The capture analyzer. This processes the frames from the camera
The frame layout showing the pinch to zoom animation
The Oval overlay view to show the face oval where the user is supposed to align their face
Whether the pinch to zoom hint has been shown (it is only shown once)
The preview view for the camera
Passive Face Capture Session
The text view to show instructions to the user
This method is used to set up the components in this activity.
This method is used to set up the listeners for the components in this activity.
Set up the tap to focus and pinch to zoom
Show an error dialog to the user. It handles SenseCryptSdkException.LivenessFailed, SenseCryptSdkException.ExtremeHeadPoseDetected, and SenseCryptSdkException.CaptureSessionTimeOut via the UIHelper methods while leaving other errors to be handled by showGeneralErrorDialog.
This method is used to show an error in the UI thread
Show general error dialog
This method is used to show the pinch to zoom hint.
Start the camera