Skip to main content

Classic UI for the Android MRZ Scanner Module

Overview

The Scanbot SDK comes with an essential camera view, additional views for extending the camera functionality and a set of the frame handler and scanner classes that handle all the camera and scanning implementation details for you. It provides a UI for MRZ scanning with guidance overlays and a camera preview.

The ScanbotCameraXView provides fully customizable camera controls and features.

Adding the feature as a dependency

MRZScanner is included in Scanbot SDK package 2. Therefore, add the dependency io.scanbot:sdk-package-2 or higher in your build.gradle along with the necessary assets:

implementation("io.scanbot:sdk-package-2:$latestVersion")
implementation("io.scanbot:sdk-mrz-assets:$latestSdkVersion")

Integration

  • ScanbotCameraXView provides fully customizable camera controls and features.
  • MrzScannerFrameHandler gives control over how and when frames are analyzed.
  • MrzScanner performs scanning and MRZ data extraction on document images.
  • FinderOverlayView selects a specific area of the camera preview to help the user pinpoint the MRZ's location and thus improve the detection rate.

Take a look at the mrz-scanner example app to see how to integrate the module.

To implement the MRZ Scanner using dedicated Android views, you need to implement an XML layout with ScanbotCamera and FinderOverlay:

MRZ Camera Layout
loading...

Then attach the scanner and configure the view's appearance and behavior:

MRZ Classic Camera
loading...

Want to scan longer than one minute?

Generate a free trial license to test the Scanbot SDK thoroughly.

Get free trial license