Class VerIDSessionSettings
- java.lang.Object
-
- com.appliedrec.verid.core2.session.VerIDSessionSettings
-
- All Implemented Interfaces:
android.os.Parcelable
- Direct Known Subclasses:
LivenessDetectionSessionSettings
,RegistrationSessionSettings
public abstract class VerIDSessionSettings extends java.lang.Object implements android.os.Parcelable
Base class for session settings- Since:
- 1.0.0
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
VerIDSessionSettings(android.os.Parcel in)
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description int
describeContents()
Describe the kinds of special objects contained in this Parcelable instance's marshaled representation.boolean
equals(java.lang.Object o)
FaceExtents
getExpectedFaceExtents()
int
getFaceCaptureCount()
Get the number of face detection results will be returned by the session.int
getFaceCaptureFaceCount()
To reduce the possibility of an unwanted face accidentally being considered in the session the service buffers a number of faces and checks that their bounds are within a given range of each other.long
getMaxDuration(java.util.concurrent.TimeUnit timeUnit)
float
getMoireDetectionConfidenceThreshold()
Deprecated.long
getPauseDuration(java.util.concurrent.TimeUnit timeUnit)
When the face is fixed the face detection will pause to allow enough time for the user to read the on-screen instructions.float
getPitchThreshold()
Get vertical (pitch) threshold where face is considered to be at an angle.float
getSpoofDeviceDetectionConfidenceThreshold()
Deprecated.float
getYawThreshold()
Get horizontal (yaw) threshold where face is considered to be at an angle.int
hashCode()
boolean
isFaceCoveringDetectionEnabled()
boolean
isMoireDetectionEnabled()
Deprecated.boolean
isPassiveLivenessDetectionEnabled()
boolean
isSessionDiagnosticsEnabled()
boolean
isSpoofDeviceDetectionEnabled()
Deprecated.void
setExpectedFaceExtents(FaceExtents expectedFaceExtents)
void
setFaceCaptureCount(int numberOfFacesToCapture)
Set the number of face detection results to collect in the session.void
setFaceCaptureFaceCount(int faceCaptureFaceCount)
void
setFaceCoveringDetectionEnabled(boolean faceCoveringDetectionEnabled)
void
setMaxDuration(long time, java.util.concurrent.TimeUnit timeUnit)
void
setMoireDetectionConfidenceThreshold(float moireDetectionConfidenceThreshold)
Deprecated.void
setMoireDetectionEnabled(boolean moireDetectionEnabled)
Deprecated.void
setPassiveLivenessDetectionEnabled(boolean passiveLivenessDetectionEnabled)
void
setPauseDuration(long pauseDuration, java.util.concurrent.TimeUnit timeUnit)
void
setPitchThreshold(float pitchThreshold)
Set vertical (pitch) threshold where face is considered to be at an angle.void
setSessionDiagnosticsEnabled(boolean sessionDiagnosticsEnabled)
void
setSpoofDeviceDetectionConfidenceThreshold(float spoofConfidenceThreshold)
Deprecated.void
setSpoofDeviceDetectionEnabled(boolean spoofDetectionEnabled)
Deprecated.void
setYawThreshold(float yawThreshold)
Set horizontal (yaw) threshold where face is considered to be at an angle.void
writeToParcel(android.os.Parcel dest, int flags)
Flatten this object in to a Parcel.
-
-
-
Method Detail
-
setMaxDuration
public void setMaxDuration(long time, java.util.concurrent.TimeUnit timeUnit)
-
getMaxDuration
public long getMaxDuration(java.util.concurrent.TimeUnit timeUnit)
-
getFaceCaptureCount
public int getFaceCaptureCount()
Get the number of face detection results will be returned by the session.- Returns:
- Number of results
- Since:
- 2.0.0
-
setFaceCaptureCount
public void setFaceCaptureCount(@IntRange(from=1L,to=5L) int numberOfFacesToCapture)
Set the number of face detection results to collect in the session.This will affect the behaviour of the session. For example, setting the value to 2 or greater will enable liveness detection on authentication and liveness detection sessions. Setting the value on a registration session will determine how many faces will be registered for the user.
- Parameters:
numberOfFacesToCapture
- Number of results to collect- Since:
- 2.0.0
-
getYawThreshold
public float getYawThreshold()
Get horizontal (yaw) threshold where face is considered to be at an angle.For example, a value of 15 indicates that a face with yaw -15 and below is oriented left and a face with yaw 15 or above is oriented right.
- Returns:
- Yaw threshold
- Since:
- 1.0.0
- See Also:
setYawThreshold(float)
-
setYawThreshold
public void setYawThreshold(@FloatRange(from=10.0,to=30.0) float yawThreshold)
Set horizontal (yaw) threshold where face is considered to be at an angle.For example, a value of 15 indicates that a face with yaw -15 and below is oriented left and a face with yaw 15 or above is oriented right.
- Parameters:
yawThreshold
- Yaw threshold- Since:
- 1.0.0
- See Also:
getYawThreshold()
-
getPitchThreshold
public float getPitchThreshold()
Get vertical (pitch) threshold where face is considered to be at an angle.For example, a value of 15 indicates that a face with pitch -15 and below is oriented up and a face with pitch 15 or above is oriented down.
- Returns:
- Pitch threshold
- Since:
- 1.0.0
- See Also:
setPitchThreshold(float)
-
setPitchThreshold
public void setPitchThreshold(@FloatRange(from=10.0,to=30.0) float pitchThreshold)
Set vertical (pitch) threshold where face is considered to be at an angle.For example, a value of 15 indicates that a face with pitch -15 and below is oriented up and a face with pitch 15 or above is oriented down.
- Parameters:
pitchThreshold
- Pitch threshold- Since:
- 1.0.0
- See Also:
getPitchThreshold()
-
getExpectedFaceExtents
public FaceExtents getExpectedFaceExtents()
-
setExpectedFaceExtents
public void setExpectedFaceExtents(FaceExtents expectedFaceExtents)
-
getPauseDuration
public long getPauseDuration(java.util.concurrent.TimeUnit timeUnit)
When the face is fixed the face detection will pause to allow enough time for the user to read the on-screen instructions. The default pause is 1 second. Decreasing the pause time will shorten the session but may lead to a frustrating user experience if the user isn't allowed enough time to read the prompts.- Parameters:
timeUnit
- Time unit in which to get the duration- Returns:
- Pause time in milliseconds
- Since:
- 2.0.0
- See Also:
setPauseDuration(long,TimeUnit)
-
setPauseDuration
public void setPauseDuration(long pauseDuration, java.util.concurrent.TimeUnit timeUnit)
- Parameters:
pauseDuration
- Duration (ms) of the pause for presenting on-screen instructions during a session- See Also:
getPauseDuration(TimeUnit)
-
getFaceCaptureFaceCount
@IntRange(from=1L, to=6L) public int getFaceCaptureFaceCount()
To reduce the possibility of an unwanted face accidentally being considered in the session the service buffers a number of faces and checks that their bounds are within a given range of each other. Decreasing the value will speed up the session but introduce the possibility of a passing face being detected and considered for recognition. Default value is 4.- Returns:
- Size of the face buffer
- Since:
- 1.0.0
- See Also:
setFaceCaptureFaceCount(int)
-
setFaceCaptureFaceCount
public void setFaceCaptureFaceCount(@IntRange(from=1L,to=6L) int faceCaptureFaceCount)
- Parameters:
faceCaptureFaceCount
- Number of faces to require for a face capture- Since:
- 1.0.0
- See Also:
getFaceCaptureFaceCount()
-
isSessionDiagnosticsEnabled
public boolean isSessionDiagnosticsEnabled()
-
setSessionDiagnosticsEnabled
public void setSessionDiagnosticsEnabled(boolean sessionDiagnosticsEnabled)
-
isFaceCoveringDetectionEnabled
public boolean isFaceCoveringDetectionEnabled()
-
setFaceCoveringDetectionEnabled
public void setFaceCoveringDetectionEnabled(boolean faceCoveringDetectionEnabled)
-
describeContents
@RestrictTo(LIBRARY_GROUP) public int describeContents()
Description copied from interface:android.os.Parcelable
Describe the kinds of special objects contained in this Parcelable instance's marshaled representation. For example, if the object will include a file descriptor in the output ofParcelable.writeToParcel(Parcel, int)
, the return value of this method must include theParcelable.CONTENTS_FILE_DESCRIPTOR
bit.- Specified by:
describeContents
in interfaceandroid.os.Parcelable
- Returns:
- a bitmask indicating the set of special object types marshaled by this Parcelable object instance.
-
writeToParcel
@RestrictTo(LIBRARY_GROUP) public void writeToParcel(android.os.Parcel dest, int flags)
Description copied from interface:android.os.Parcelable
Flatten this object in to a Parcel.- Specified by:
writeToParcel
in interfaceandroid.os.Parcelable
- Parameters:
dest
- The Parcel in which the object should be written.flags
- Additional flags about how the object should be written. May be 0 orParcelable.PARCELABLE_WRITE_RETURN_VALUE
.
-
equals
@RestrictTo(LIBRARY_GROUP) public boolean equals(java.lang.Object o)
- Overrides:
equals
in classjava.lang.Object
-
hashCode
@RestrictTo(LIBRARY_GROUP) public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
isSpoofDeviceDetectionEnabled
@Deprecated public boolean isSpoofDeviceDetectionEnabled()
Deprecated.- Returns:
- true if spoof device detection is enabled
- Since:
- 2.7.0
-
setSpoofDeviceDetectionEnabled
@Deprecated public void setSpoofDeviceDetectionEnabled(boolean spoofDetectionEnabled)
Deprecated.- Parameters:
spoofDetectionEnabled
- Set to false to disable spoof device detection- Since:
- 2.7.0
-
getSpoofDeviceDetectionConfidenceThreshold
@Deprecated public float getSpoofDeviceDetectionConfidenceThreshold()
Deprecated.- Returns:
- Spoof device detection confidence threshold
- Since:
- 2.7.0
-
setSpoofDeviceDetectionConfidenceThreshold
@Deprecated public void setSpoofDeviceDetectionConfidenceThreshold(float spoofConfidenceThreshold)
Deprecated.- Parameters:
spoofConfidenceThreshold
- New spoof device detection confidence threshold- Since:
- 2.7.0
-
isMoireDetectionEnabled
@Deprecated public boolean isMoireDetectionEnabled()
Deprecated.- Returns:
- true if moire detection is enabled
- Since:
- 2.7.0
-
setMoireDetectionEnabled
@Deprecated public void setMoireDetectionEnabled(boolean moireDetectionEnabled)
Deprecated.- Parameters:
moireDetectionEnabled
- Set to false to disable moire detection- Since:
- 2.7.0
-
getMoireDetectionConfidenceThreshold
@Deprecated public float getMoireDetectionConfidenceThreshold()
Deprecated.- Returns:
- Moire detection confidence threshold
- Since:
- 2.7.0
-
setMoireDetectionConfidenceThreshold
@Deprecated public void setMoireDetectionConfidenceThreshold(float moireDetectionConfidenceThreshold)
Deprecated.- Parameters:
moireDetectionConfidenceThreshold
- New moire detection confidence threshold- Since:
- 2.7.0
-
isPassiveLivenessDetectionEnabled
public boolean isPassiveLivenessDetectionEnabled()
- Returns:
- true if passive liveness detection is enabled
- Since:
- 2.9.0
-
setPassiveLivenessDetectionEnabled
public void setPassiveLivenessDetectionEnabled(boolean passiveLivenessDetectionEnabled)
- Parameters:
passiveLivenessDetectionEnabled
- Set to true to enable passive liveness detection- Since:
- 2.9.0
-
-