Mit Sammlungen den Überblick behalten
Sie können Inhalte basierend auf Ihren Einstellungen speichern und kategorisieren.
Dokumentenscanner
Die Digitalisierung physischer Dokumente, die es Nutzern ermöglicht, physische Dokumente in digitale Formate umzuwandeln, ist in mobilen Apps zu einem sehr verbreiteten Prozess geworden.
Die Document Scanner API von ML Kit bietet eine umfassende Lösung mit einem hochwertigen, konsistenten UI-Flow für Android-Apps und -Geräte. Sobald der Dokumentenscanner über Ihre Anwendung ausgelöst wird, behalten die Nutzer die volle Kontrolle über den Scanvorgang. Sie können die gescannten Dokumente optional zuschneiden, Filter anwenden, Schatten oder Flecken entfernen und die digitalisierten Dateien einfach an Ihre Anwendung zurücksenden.
Der UI-Ablauf, ML-Modelle und andere große Ressourcen werden mithilfe von Google Play-Diensten bereitgestellt. Das bedeutet:
Geringe Auswirkungen auf die binäre Größe (alle ML-Modelle und großen Ressourcen werden zentral in Google Play-Diensten heruntergeladen).
Es ist keine Kameraberechtigung erforderlich. Der Dokumentenscanner verwendet die Kameraberechtigung der Google Play-Dienste und die Nutzer können festlegen, welche Dateien für Ihre App freigegeben werden.
Der gesamte Ablauf des Dokumentenscanners wird auf dem Gerät ausgeführt.
Hochwertige und einheitliche Benutzeroberfläche zum Digitalisieren physischer Dokumente.
Automatische Erfassung mit Dokumenterkennung.
Genaue Kantenerkennung für optimale Zuschnittergebnisse
Automatische Erkennung der Drehung, um Dokumente aufrecht zu zeigen
Bearbeitungsfunktionen zum Zuschneiden, Anwenden von Filtern, Entfernen von Schatten, Entfernen von Flecken und nahtloses Senden digitalisierter Dateien an Ihre App
Verarbeitung auf dem Gerät unter Wahrung des Datenschutzes für Nutzer
Es ist keine Kameraberechtigung von Ihrer App aus erforderlich.
Geringe Auswirkungen auf die APK-Binärgröße.
Anpassbare
Die Document Scanner API bietet einen hochwertigen, vollwertigen UI-Ablauf, der in allen Android-Apps einheitlich ist. Es ist jedoch auch möglich, einige Aspekte der User Experience anzupassen:
Maximale Seitenanzahl:
Legen Sie eine Beschränkung für die Anzahl der gescannten Seiten fest.
Galerieimport:
Hier können Sie die Funktion zum Importieren aus der Fotogalerie aktivieren oder deaktivieren.
Bearbeitungsfunktionen:
Sie können die Bearbeitungsfunktionen, die Nutzern zur Verfügung stehen, mithilfe von drei Modi anpassen:
SCANNER_MODE_BASE: grundlegende Bearbeitungsfunktionen (z. B. Zuschneiden, Drehen, Neuanordnen von Seiten)
SCANNER_MODE_BASE_WITH_FILTER: fügt dem SCANNER_MODE_BASE-Modus Bildfilter (Graustufen, automatische Bildoptimierung usw.) hinzu.
SCANNER_MODE_FULL (Standard): fügt dem SCANNER_MODE_BASE_WITH_FILTER-Modus ML-fähige Funktionen zur Bildbereinigung hinzu, z. B. Flecken und Finger entfernen. In diesem Modus können zusammen mit Updates für Google Play-Dienste auch zukünftige wichtige Funktionen automatisch hinzugefügt werden. Die anderen beiden Modi behalten ihre aktuellen Funktionen bei und erhalten nur kleinere Optimierungen.
Basismodus
Basismodus mit Filter
Alle Zugriffe
Beispielergebnisse
Originalbild
Gescanntes Dokument mit korrigierter Perspektive, Entfernung von Falten und angewendetem Graustufenfilter
Originalbild
Gescanntes Dokument automatisch gedreht, Fleck entfernt und Farbfilter angewendet
Originalbild
Gescanntes Dokument mit entferntem Fleck und automatischem Filter
Originalbild
Gescanntes Dokument automatisch gedreht, Schatten entfernt und automatisch Filter angewendet
Originalbild
Gescanntes Dokument automatisch gedreht, Finger entfernt und automatisch Filter angewendet
[null,null,["Zuletzt aktualisiert: 2025-07-25 (UTC)."],[[["\u003cp\u003eML Kit's Document Scanner API enables digitization of physical documents within Android apps, providing a high-quality and consistent user interface.\u003c/p\u003e\n"],["\u003cp\u003eThe API offers on-device processing, ensuring user privacy and eliminating the need for camera permissions from the app.\u003c/p\u003e\n"],["\u003cp\u003eUsers have control over the scanning process, including cropping, applying filters, removing imperfections, and sharing the digitized files.\u003c/p\u003e\n"],["\u003cp\u003eCustomization options are available to tailor the user experience, such as limiting pages, enabling gallery imports, and adjusting editing functionalities.\u003c/p\u003e\n"],["\u003cp\u003eThe API leverages Google Play services for model delivery, minimizing app size and enabling automatic updates for enhanced features.\u003c/p\u003e\n"]]],["The document scanner API allows users to digitize physical documents within Android apps. Key actions include automatic document capture, edge and rotation detection, and editing features like cropping, filtering, and stain/shadow removal. The API operates on-device and uses Google Play services, ensuring low binary size impact and eliminating the need for camera permissions. Customization options are provided for the maximum number of pages, gallery import, and three editing modes, with the full mode offering the most feature set.\n"],null,["Document scanner\n----------------\n\n| This API is offered in beta, and is not subject to any SLA or deprecation policy. Changes may be made to this API that break backward compatibility.\n\nDigitizing physical documents, which allows users to convert physical documents\ninto digital formats has become a very common user journey in mobile apps.\nML Kit's document scanner API provides a comprehensive solution with a\nhigh-quality, consistent UI flow across Android apps and devices. Once the\ndocument scanner flow is triggered from your app, users retain full control over\nthe scanning process. They can optionally crop the scanned documents, apply\nfilters, remove shadows or stains, and easily send the digitized files back to\nyour app.\n\nThe UI flow, ML models and other large resources are delivered using Google Play\nservices, which means:\n\n- Low binary size impact (all ML models and large resources are downloaded centrally in Google Play services).\n- No camera permission is required - the document scanner leverages the Google Play services' camera permission, and users are in control of which files to share back with your app.\n\nThe entire document scanner flow operates on-device.\n\n[Android](/ml-kit/vision/doc-scanner/android)\n\n### Key capabilities\n\n- High-quality and consistent user interface for digitizing physical documents.\n- Automatic capture with document detection.\n- Accurate edge detection for optimal crop results.\n- Automatic rotation detection to show documents upright.\n- Editing functionalities to crop, apply filters, remove shadows, clean stains, and seamlessly send digitized files back to your app.\n- On-device processing, preserving user's privacy.\n- No camera permission is needed from your app.\n- Low apk binary size impact.\n\n### Customization\n\nThe document scanner API provides a high-quality fully fledged UI flow that is\nconsistent across Android apps. However, there is also room to customize some\naspects of the user experience:\n\n- **Maximum number of pages:** \n\n Set a limit to the number of pages scanned.\n\n- **Gallery import:** \n\n Enable or disable the capability to import from the photo gallery.\n\n- **Editing functionalities:** \n\n Customize the editing functionalities available to the user by choosing\n from 3 modes:\n\n - `SCANNER_MODE_BASE`: basic editing capabilities (crop, rotate, reorder pages, etc...).\n - `SCANNER_MODE_BASE_WITH_FILTER`: adds image filters (grayscale, auto image enhancement, etc...) to the `SCANNER_MODE_BASE` mode.\n - `SCANNER_MODE_FULL` (default): adds ML-enabled image cleaning capabilities (erase stains, fingers, etc...) to the `SCANNER_MODE_BASE_WITH_FILTER` mode. This mode will also allow future major features to be automatically added along with Google Play services updates, while the other two modes will maintain their current feature sets and only receive minor refinements.\n\n| Base mode | Base mode with filter | Full mode |\n|-----------|-----------------------|-----------|\n| | | |\n\n### Example results\n\n| Original picture | Scanned document with perspective corrected, wrinkle removed and grayscale filter applied |\n|------------------|-------------------------------------------------------------------------------------------|\n| | |\n\n| Original picture | Scanned document auto-rotated with stain removed and color filter applied |\n|------------------|---------------------------------------------------------------------------|\n| | |\n\n| Original picture | Scanned document with stain removed and auto filter applied |\n|------------------|-------------------------------------------------------------|\n| | |\n\n| Original picture | Scanned document auto-rotated with shadow removed and auto filter applied |\n|------------------|---------------------------------------------------------------------------|\n| | |\n\n| Original picture | Scanned document auto-rotated with finger removed and auto filter applied |\n|------------------|---------------------------------------------------------------------------|\n| | |"]]