TechTrue® Android SDK  

V1.3.7

Android SDK for TechTrue®'s face recognition
br.com.techmag.ttface.TTPerson Class Reference

Classes

enum  TTPersonStatus
 

Public Member Functions

void setCheckLiveness (boolean enabled)
 
void setExtId (String extId)
 
String getExtId ()
 
void addImage (TTImage img)
 
void addImage (InputStream input)
 
void addTemplate (TTTemplate tpl)
 
Vector< String > getTemplates ()
 
TTImage getImage ()
 
void enroll () throws TTException
 
void update () throws TTException
 
void delete () throws TTException
 
int verify () throws TTException
 
int identify () throws TTException
 

Detailed Description

This class represents a Person object and provides all the necessary functionalities for enrollment, verification and identification.

Member Function Documentation

◆ addImage() [1/2]

void br.com.techmag.ttface.TTPerson.addImage ( InputStream  input)
inline

Adds an image to this person from an InputStream

Parameters
inputInputStream object

◆ addImage() [2/2]

void br.com.techmag.ttface.TTPerson.addImage ( TTImage  img)
inline

Adds an image to this person from TTImage object

Parameters
imgTTImage obejct

◆ addTemplate()

void br.com.techmag.ttface.TTPerson.addTemplate ( TTTemplate  tpl)
inline

Adds a face template to this person. Mainly used for enrolling a person from a template, instead of an image, which makes the process faster.

Parameters
tplTTTemplate object

◆ delete()

void br.com.techmag.ttface.TTPerson.delete ( ) throws TTException
inline

Deletes this person from DB. This removes everything and it's not possible to recover.

Exceptions
TTExceptionWhen could not delete person from DB

◆ enroll()

void br.com.techmag.ttface.TTPerson.enroll ( ) throws TTException
inline

Enrolls this person to DB. Involves feature extraction and DB persistence.

In case a template is set for this person, only the DB persistence happens, which is much faster and it's the recommended way to pre-load a new device.

Exceptions
TTExceptionWhen no faces were found in the pictures

◆ getExtId()

String br.com.techmag.ttface.TTPerson.getExtId ( )
inline

Gets this person's External ID

Returns
External ID as String

◆ getImage()

TTImage br.com.techmag.ttface.TTPerson.getImage ( )
inline

Get the person's associated image

Returns
TTImage object containing the image

◆ getTemplates()

Vector<String> br.com.techmag.ttface.TTPerson.getTemplates ( )
inline

Gets the templates of this person. When enrolling from images, these templates will only be available after calling the enroll method.

Returns
Vector of strings. Each string is a template encoded in base64.

◆ identify()

int br.com.techmag.ttface.TTPerson.identify ( ) throws TTException
inline

Identifies a person in the DB.

This means an 1:N biometric operation, to check if the provided person's image is contained in the DB, and who is that person.

If a person is correctly identified, its attributes will be set in the calling object.

Returns
Positive integer if person is correctly identified, 0 otherwise.
Exceptions
TTExceptionWhen no faces were found in the pictures

◆ setCheckLiveness()

void br.com.techmag.ttface.TTPerson.setCheckLiveness ( boolean  enabled)
inline

Sets if the Liveness check will be performed or not.
When set to true, all methods called on this person object will perform the liveness check, otherwise this check will be skipped.
Default: true

Parameters
enabledtrue will perform liveness checks; false will skip liveness checks.

◆ setExtId()

void br.com.techmag.ttface.TTPerson.setExtId ( String  extId)
inline

Sets an External ID to this person

Parameters
extIdExternal ID

◆ update()

void br.com.techmag.ttface.TTPerson.update ( ) throws TTException
inline

Updates this person on DB. Only feature descriptor is updated.

◆ verify()

int br.com.techmag.ttface.TTPerson.verify ( ) throws TTException
inline

Verifies this person against the DB. This means an 1:1 biometric operation, to ensure the provided person is the same as the one persisted in the DB.

Returns
Positive integer if person is correctly verified, 0 otherwise.
Exceptions
TTExceptionWhen no faces were found in the pictures