Skip to content

Not working with vision camera v4 #6

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
Vadko opened this issue Nov 2, 2024 · 8 comments
Closed

Not working with vision camera v4 #6

Vadko opened this issue Nov 2, 2024 · 8 comments

Comments

@Vadko
Copy link

Vadko commented Nov 2, 2024

I've installed library within my own project and there were 2 issues on ios (not tested android):

  1. Library doesn't recognize mrz labels
  2. App crashes in debug mode when trying to read data from MRZ because of memory leak

Then I've tried to clone example repo and result was the same. I assume that something is wrong with library specifically for v4, because v3 example worked perfectly in my case.

@tony-xlh
Copy link
Owner

tony-xlh commented Nov 4, 2024

I think this is related to two issues in v4:

  1. The overlay is not accurate. You have to use skia to draw the camera preview: 🐛 Camera preview is not showing the full content mrousavy/react-native-vision-camera#3231
  2. runAsync has a memory problem: 🐛 runAsync has memory problem mrousavy/react-native-vision-camera#3202

You can try this demo to see if the cropped image is correct: https://github.com/tony-xlh/react-native-id-card-scanner

@Vadko
Copy link
Author

Vadko commented Nov 7, 2024

Thanks for sharing this example - it works perfectly fine. However, when trying to put it together with document-normalizer plugin you created - it doesnt work because of DynamsoftCore version difference. Is it something that could be changed?

@xulihang
Copy link
Collaborator

xulihang commented Nov 8, 2024

I have to update the label recognizer plugin to make it compatibile with the document normalizer plugin.

@xulihang
Copy link
Collaborator

xulihang commented Nov 26, 2024

I've updated the two plugins to make them work together.

@Vadko
Copy link
Author

Vadko commented Nov 26, 2024

many thanks for your update. are there any plans for new architecture?

@xulihang
Copy link
Collaborator

The new capture vision architecture is actually used under the hood. It's just the interface exposed is still the old.

The new react native package uses the new architecture: https://www.npmjs.com/package/dynamsoft-capture-vision-react-native/v/2.4.2000-alpha.3

@Vadko
Copy link
Author

Vadko commented Nov 27, 2024

just tried latest label-recognizer - how are models supposed to be used now if useCustomModel was removed?🤔

@xulihang
Copy link
Collaborator

The MRZ model is now included by default.

@tony-xlh tony-xlh closed this as completed Dec 4, 2024
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

No branches or pull requests

3 participants