Skip to content

Conversation

Raz1e1
Copy link

@Raz1e1 Raz1e1 commented May 19, 2025

This introduces a new option the the ScanDocumentOptions to allow the configuration of the used scanner mode on android.

https://developers.google.com/ml-kit/vision/doc-scanner#customization

The supported modes are

SCANNER_MODE_BASE: basic editing capabilities (crop, rotate, reorder pages, etc…).
SCANNER_MODE_BASE_WITH_FILTER: adds image filters (grayscale, auto image enhancement, etc…) to the SCANNER_MODE_BASE mode.
SCANNER_MODE_FULL (default): adds ML-enabled image cleaning capabilities (erase stains, fingers, etc…) to the 

The option can be set like this

    const {scannedImages, status} = await DocumentScanner.scanDocument({
      maxNumDocuments: 50,
      androidScannerMode: AndroidScannerMode.ScannerModeBase
    });

Also upgraded the gradle build tools.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants