Biometrid IOS SDK
3.0.2
3.0.2
  • Introduction
  • Standard SDK
    • Prerequisites
    • Requirements
    • Initialization
    • Enums
    • Installation
      • Zip file
      • CocoaPods
    • Process Management
      • Create process
      • Get Step State
      • Update Step
      • Previous Step
    • Liveness Detection
    • Auto Capture
      • MRZ Capture
      • Configurations
    • Camera
      • Configurations
    • NFC
      • Scan Result
      • Configurations
    • Video Conference
    • Biometric Authentication
      • Configurations
    • Device Location
      • Configurations
    • Presence Detection
      • Configurations
  • FULL SDK
    • Requirements
    • Usage
    • Installation
      • Zip file
      • CocoaPods
    • Initialization
    • Start
    • Stop
    • Callbacks
Powered by GitBook
On this page
  • Implementation example:
  • Models

Was this helpful?

  1. Standard SDK
  2. Auto Capture

Configurations

This section describes all options to configure the camera preview.

This SDK is customizable and allows to choose options to configure the shown texts, colors, buttons, timers and object detection parameters.

Implementation example:

let style = CaptureStyleOptions(textColor: .black, 
textBackground: UIColor(red: 1, green: 1, blue: 1, alpha: 0.3), 
overlayColor: .black, overlaySuccessColor: .green)
let texts = CaptureTextOptions(text: "Subtitle")
let photoOptions = InactiveOptions(active: true, timer: 60)
let options = CaptureOptions(takePhoto: photoOptions, i18n: texts, style: style)
// Starts Document Capture SDK
BiometridStandard.getInstance().startAutoCapture(viewController: self, options: options, callback: self)

For more information about each possible configuration see the corresponding data model below:

Models

CaptureOptions
Description

type: CaptureType

Determines the type of objects the camera is allowed to detect. Defaults to idcard.

threshold: CGFloat?

Adjusts the minimum score limit for the detected objects to be considered optimal within a range of [0.0, 1.0].

Defaults to 0.75.

margin: Int?

Adds a margin of pixels around the captured image. Must be >= 0.

cameraChange: Bool?

Determines the visibility of the button to switch between the available camera.

Defaults to true.

enablePortrait: Bool?

When enabled, allows the camera to be used in portrait mode.

Defaults to false.

timerCapture: Int?

The time in seconds until a photo is captured from the moment an object is detected. Must be > 0.

Defaults to 2 (seconds).

takePhoto: Bool

Defines if has available options to take manual photo. Defaults to true.

enableInactive: InactiveOptions?

Defines the configurations for inactivity popup. Defaults to true and 30 (seconds).

i18n: CaptureTextOptions?

Defines the texts used for the camera preview.

style: CaptureStyleOptions?

Defines the colors for the camera preview.


InactiveOptions
Description

active: Bool?

Determines if inactivity popup should appear.

Defaults to true.

timer: Int?

Time of inactivity permitted, from the moment the camera was started. Must be > 0.

Defaults to 30 (seconds).


CaptureTextOptions
Description

text: String?

Defines the overlay frame text.

holdStill: String?

Defines the text shown when a document is detected inside the frame.

error: String?

Defines the text shown when a document has an error.

invalid: String?

Defines the text shown when a document is invalid.

success: String?

Defines the text shown when a document is successfully scanned.

outOfFocus: String?

Defines the text shown when a document is out of focus.


CaptureStyleOptions
Description

textColor: UIColor?

Defines the color for the texts.

textBackground: UIColor?

Defines the color for text backgrounds.

overlayColor: UIColor?

Defines the color for the overlay frame when no objects are detected.

overlayActionColor: UIColor?

Defines the color for the overlay frame when an object is being detected.

overlaySuccessColor: UIColor?

Defines the color for the overlay frame when an object is detected.

overlayErrorColor: UIColor?

Defines the color for the overlay frame when an object has an error.

overlayWarningColor: UIColor?

Defines the color for the overlay frame when an object is out of focus.


CaptureType - enum
Description

idcard

Scan objects of type "card".

passport

Scan objects of type "passport".


MRZData
Description

passportNumber: String

Passport number of mrz scan

dateOfBirth: Date

Date of birth of mrz scan

expiryDate: Date

Expiry date of mrz scan

PreviousMRZ CaptureNextCamera

Was this helpful?