NeutrinosPlatform / cordova-plugin-document-scanner

cordova plugin for document scan
https://www.neutrinos.co/
MIT License
84 stars 63 forks source link

Android - Document Scanner not working from device camera #98

Open ShaneLucy opened 3 years ago

ShaneLucy commented 3 years ago

Describe the bug

When loading the document scanner on Android with source type set to 1, the camera loads without support for detecting document edges and after taking a picture the document scanner closes with the following error Incorrect result or user canceled the action

With source type set to 1, so that the image is being loaded from the file system, the document scanner works as expected.

To Reproduce

Steps to reproduce the behavior:

  1. Create a new ionic/vue starter project
  2. Follow the installation & usage instructions for cordova-plugin-document-scanner
  3. Sync and run for android
  4. Build from Android Studio
  5. Activate Document Scanner
  6. Take Picture
  7. Select Picture
  8. Error appears in console

Expected behavior

The document scanner to load the camera with edge detection and return either the url or base64 image

Smartphone:

Emulated

Physical

Additional context

The issue can't be reproduced on iOS

ChrisTomAlx commented 3 years ago

Hey Could you try with the beta version, follow the steps here

Cheers, Chris Neutrinos

RagasaSP commented 3 years ago

Any update on this? Happens to me right now.

My app was working without problem and this error started to appear out of nowhere.

marco-itlabs commented 2 years ago

Hey Could you try with the beta version, follow the steps here

Cheers, Chris Neutrinos

We faced the same issue on some Android devices. Updating to plugin version to 5.0.0-beta.1 seems to solve the problem. Thank you!