Skip to content

Installation on iOS

How to install Document Reader SDK.

Overview

graph LR
  A(Document Reader SDK) --> B(API);
  A --> C(Core);
  B --> D(Common);
  A -.- E[(Database)];

The Document Reader SDK consists of two frameworks: API and Core.

The API framework provides the external interface for controlling the process and getting the result. It depends on the Common framework that is an interface for working with the camera and other modules that are used in other Regula SDKs.

The Core framework provides the recognition functionality where all the processing happens. This is the internal framework, it is used by the API framework only and is not accessible for developers. However, it should be referenced in the project.

The database contains the documents' data. It's mandatory to have it if you use the Core type that supports document type recognition.

Requirements

  • The latest stable version of Xcode.

  • Minimum target: iOS 11.0.

Installation

CocoaPods

To always use the latest release, add the following to your Podfile:

Podfile
1
2
pod 'DocumentReader'
pod 'DocumentReaderFullRFID'

Alternatively, you can pin to a specific version (e.g. 1.0.0):

Podfile
1
2
pod 'DocumentReader', '1.0.0'
pod 'DocumentReaderFullRFID', '1.0.0'

And then run in Terminal the command below to install pods in your project:

pod install

Manual Integration

1. Download the latest API framework.

2. Download the latest Common framework.

3. Download one of the Core frameworks depending on the functionality you need and the license capabilities.

4. Drag DocumentReader.xcframework, DocumentReaderCore.xcframework, and RegulaCommon.xcframework frameworks into the Frameworks, Libraries, and Embedded Content section of your target:

5. Build and run the project.

Core Types

There is a variety of the Core framework types, each has different features included.

Find the list of available features in the table below.

Feature Description
Visual zone OCR Optical character recognition of the document visual zone text fields based on document templates included in the database.
Document type identification Automatic recognition of the document type: no need to manually select a country, document type, and series for processing.
MRZ OCR Reading and parsing the machine readable zone lines into separate fields.
Barcode recognition Reading the 1D and 2D (PDF417, QR, Aztec, Datamatrix) barcodes and automatic parsing into text fields using included document template specifications if the template database is available and the document type is identified.
Document location Detecting the document boundaries and cropping out the document from the supplied picture.
Graphics cropping Cropping graphic fields, such as a photo portrait and signature, based on templates included in the database.
RFID chip processing Reading data from electronic contactless chips of ePassport, eID, and eDL using NFC hardware, if present.
Security features check For each document type, certain secutiry checks can be performed. For example, UV dull paper check, image patterns (VIS), IR transparency, etc. You can find the security checks by document types in the Documents list.

The size of the Core framework depends on the features included, so choose the one that suits your case the best to optimize the size of your application.

Podfile
pod 'DocumentReaderFullRFID'

Features:

  • Visual zone OCR
  • Document type identification
  • MRZ OCR
  • Barcode recognition
  • Document location
  • Graphics cropping
  • RFID chip processing
  • Checking security features

Notes:

Podfile
pod 'DocumentReaderFull'

Features:

  • Visual zone OCR
  • Document type identification
  • MRZ OCR
  • Barcode recognition
  • Document location
  • Graphics cropping
  • RFID chip processing
  • Checking security features

Notes:

Podfile
pod 'DocumentReaderOCR'

Features:

  • Visual zone OCR
  • Document type identification
  • MRZ OCR
  • Barcode recognition
  • Document location
  • Graphics cropping
  • RFID chip processing
  • Checking security features

Notes:

Podfile
pod 'DocumentReaderMRZ'

Features:

  • Visual zone OCR
  • Document type identification
  • MRZ OCR
  • Barcode recognition
  • Document location
  • Graphics cropping
  • RFID chip processing
  • Checking security features

Notes:

Podfile
pod 'DocumentReaderBarcode'

Features:

  • Visual zone OCR
  • Document type identification
  • MRZ OCR
  • Barcode recognition
  • Document location
  • Graphics cropping
  • RFID chip processing
  • Checking security features

Notes:

Podfile
pod 'DocumentReaderFullAuthRFID'

Features:

  • Visual zone OCR
  • Document type identification
  • MRZ OCR
  • Barcode recognition
  • Document location
  • Graphics cropping
  • RFID chip processing
  • Checking security features

Notes:

Podfile
pod 'DocumentReaderMRZBarcode'

Features:

  • Visual zone OCR
  • Document type identification
  • MRZ OCR
  • Barcode recognition
  • Document location
  • Graphics cropping
  • RFID chip processing
  • Checking security features

Notes:

Podfile
pod 'DocumentReaderMRZRFID'

Features:

  • Visual zone OCR
  • Document type identification
  • MRZ OCR
  • Barcode recognition
  • Document location
  • Graphics cropping
  • RFID chip processing
  • Checking security features

Notes:

Podfile
pod 'DocumentReaderDocType'

Features:

  • Visual zone OCR
  • Document type identification
  • MRZ OCR
  • Barcode recognition
  • Document location
  • Graphics cropping
  • RFID chip processing
  • Checking security features

Notes:

Podfile
pod 'DocumentReaderOCRRFID'

Features:

  • Visual zone OCR
  • Document type identification
  • MRZ OCR
  • Barcode recognition
  • Document location
  • Graphics cropping
  • RFID chip processing
  • Checking security features

Notes:

Podfile
pod 'DocumentReaderMRZBarcode'

Features:

  • Visual zone OCR
  • Document type identification
  • MRZ OCR
  • Barcode recognition
  • Document location
  • Graphics cropping
  • RFID chip processing
  • Checking security features

Notes:

Podfile
pod 'DocumentReaderFullAuth'

Features:

  • Visual zone OCR
  • Document type identification
  • MRZ OCR
  • Barcode recognition
  • Document location
  • Graphics cropping
  • RFID chip processing
  • Checking security features

Notes:

Podfile
pod 'DocumentReaderBounds'

Features:

  • Visual zone OCR
  • Document type identification
  • MRZ OCR
  • Barcode recognition
  • Document location
  • Graphics cropping
  • RFID chip processing
  • Checking security features

Notes:

Info

If you are not sure yet which Core type to choose, consider the fullrfid one. You will be able to get back and change your decision at any moment.

Next Steps