More Premium Hugo Themes Premium React Themes

React Native Document Scanner

Document scanner, features live border detection, perspective correction, image filters and more !

React Native Document Scanner

Document scanner, features live border detection, perspective correction, image filters and more !

Github Stars Github Stars: 881
Last Commit Last Commit: Jan 22, 2020 -
First Commit Created: Feb 24, 2024 -
React Native Document Scanner screenshot

Overview

The React Native Document Scanner is a live document detection library that allows users to capture images and returns either a URI or a base64 encoded string of the captured image. It offers features like live detection, perspective correction, camera filters, flash, and easy storage options for images.

Features

  • Live detection: Real-time detection of documents
  • Perspective correction and crop: Automatically corrects perspective and crops the image
  • Live camera filters: Adjust brightness, saturation, and contrast during image capture
  • Flash: Easily toggle the flash on or off
  • Base64 image: Images can be returned in base64 format for easy storage

Installation

To install the React Native Document Scanner, use the following steps:

  1. Ensure you are using version >=1.4.1 for React Native 0.48+
  2. Add the library using yarn:
    $ yarn add https://github.com/Michaelvilleneuve/react-native-document-scanner
    
  3. Link the library:
    $ react-native link react-native-document-scanner
    
  4. Edit the info.plist file in Xcode and add the following permission:
    NSCameraUsageDescription
    
  5. For Android:
    • If OpenCV is not linked in your project, add it to settings.gradle
    • Update AndroidManifest.xml with necessary changes to avoid manifest merger errors

Summary

The React Native Document Scanner is a versatile library for capturing documents live. With features like perspective correction, live camera filters, and easy image storage options, this library simplifies the process of integrating document scanning functionality into React Native applications. The provided installation guide ensures a smooth setup process for both iOS and Android platforms.