Kofax Mobile SDK API Reference
Instance Methods | Properties | List of all members
kfxKOEIDExtractor Class Reference

The ID Extractor Class. More...

#import <kfxKOEIDExtractor.h>

Inheritance diagram for kfxKOEIDExtractor:

Instance Methods

(instancetype) - initWithProjectProvider:
 Constructor for custom project provider. More...
 
(void) - extract:
 Use this method to start extraction. More...
 
(void) - cancelExtraction
 Use this method to cancel the extraction. More...
 

Properties

id< kfxKOEIDExtractorDelegatedelegate
 kfxKOEIDExtractorDelegate notifies about extraction completion More...
 
id< kfxKOEIDImageProcessingDelegateimageProcessingDelegate
 kfxKOEIDImageProcessingDelegate notifies about image processing completion More...
 

Detailed Description

The ID Extractor Class.

Framework: libKfxEngines Import suggestion: #import <kfxLibEngines/kfxEngines.h> Relevant Header File: kfxKOEIDExtractor.h An instance of this class contains methods to extract data from ID images.

Initialization** [kfxKOEIDExtractor new] (or [[kfxKOEIDExtractor alloc] init]) - default constructor, the extractor will be initialized with default KFXLocalBundleProjectProvider automatically.

[[kfxKOEIDExtractor alloc] initWithProjectProvider:provider] - the extractor will be initialized with provided id<KFXProjectProviderProtocol> project provider.

Processing** The extractor requires the image(s) to either be cropped before performing the extraction, or the KFXIDExtractionParameters::isProcessed flag to be set to false. To get the most accurate results, send uncropped images. Otherwise, most ID images can be cropped using the kfxKENImageProcessor with the following operation string: "_DeviceType_2_Do90DegreeRotation_4_DoCropCorrection__DoScaleImageToDPI_500_DoSkewCorrectionPage__DocDimLarge_3.375_DocDimSmall_2.125_LoadSetting_<Property Name=\"CSkewDetect.correct_illumination.Bool" Value="0" />"

If the image was preprocessed differently, the extraction results may not be accurate. For more information on preprocessing Passports or IDs with less common dimensions, please refer to the MobileID documentation.

Licensing**

Extractor requires a valid license to be set. It should have enough license count for LIC_ON_DEVICE_EXTRACTION feature.

Note: The extractor uses several Optical Character Recognition (OCR) engines for the extraction. Tesseract OCR engine is used for non-latin characters recognition. By default Tesseract OCR engine is disabled and its binaries will not influence application size. In order to enable Tesseract OCR engine, call enable class method before run kfxKOEIDExtractor's extract.

See also
KFXTesseractOCR
kfxKUTLicensing
KFXProjectProviderProtocol
KFXLocalBundleProjectProvider

Method Documentation

- (void) cancelExtraction

Use this method to cancel the extraction.

If this method is called during the extraction, extractionResults:error: method of the kfxKOEIDExtractorDelegate will be called, containing KMC_EX_CANCEL_OPERATION_SUCCESS error for corresponding ID sides. When the callback is received, you may start new extraction.

If new extraction is started before receiving extractionResult callback, the behavior is undefined.

See also
kfxKOEIDExtractorDelegate
- (void) extract: (KFXIDExtractionParameters *)  parameters

Use this method to start extraction.

This method starts the extraction with specified extraction parameters. Parameters will be verified before the extraction. In case of invalid parameters an appropriate error will be returned via delegate. If other extract call is received while previous extraction is in progress, KMC_EX_BUSY error will be sent.

Parameters
parameters- a KFXIDExtractionParameters object with extraction parameters.
See also
KFXIDExtractionParameters
kfxKOEIDExtractorDelegate
- (instancetype) initWithProjectProvider: (id< KFXProjectProviderProtocol >)  projectProvider

Constructor for custom project provider.

This constructor allows to specify custom project provider to be used to get extraction assets.

Parameters
projectProvider- a project provider instance which conforms to KFXProjectProviderProtocol protocol.
See also
KFXProjectProviderProtocol

Property Documentation

- (id<kfxKOEIDExtractorDelegate>) delegate
readwritenonatomicweak

kfxKOEIDExtractorDelegate notifies about extraction completion

This delegate must be set in order for your app to receive delegate calls.

See also
kfxKOEIDExtractorDelegate
- (id<kfxKOEIDImageProcessingDelegate>) imageProcessingDelegate
readwritenonatomicweak

kfxKOEIDImageProcessingDelegate notifies about image processing completion

The delegate is called when either the front or back image processing is complete. This delegate must be set before extraction is started for your app to receive delegate calls. Wait for the kfxKOEIDExtractorDelegate callback before clearing or editing the recieved bitmaps.

See also
kfxKOEIDImageProcessingDelegate
kfxKOEIDExtractorDelegate

The documentation for this class was generated from the following file:
Untitled Document © 2018 Kofax, Inc. All rights reserved. Use is subject to license terms.