Skip to content
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

Recognized scan-region for small viewports #26

Closed
OneDivZero opened this issue Apr 30, 2020 · 10 comments
Closed

Recognized scan-region for small viewports #26

OneDivZero opened this issue Apr 30, 2020 · 10 comments
Assignees

Comments

@OneDivZero
Copy link

OneDivZero commented Apr 30, 2020

Bug
There seems to be a problem with the recognized scan-region for small viewports. I printed a qr-code in the size of a hand and I'm trying it to scan with an iPhone 7 using a qr-box with 350x350px (and boxsize in code is not set, thus it should use full dimension).

You have to hold your phone about 0,5m far away only for having a chance to get a match. And then it only succeeds in round about one out of ten trials. It works great with macbook-cam, when using a qr-box with more than 600+ px. But reducing step by step the size also works bad on desktop browser.

Describe the browser:

  • OS: iOS on iPhone 7
  • Browser: Safari
  • Version: latest

Screenshots
Fails on desktop too:

202004120_200432-CapturFiles

Additional context
Box: 350x350
BoxSize in JS: null

I can provide a playground if required.

@OneDivZero OneDivZero changed the title Compatibility - [OS] [Browser] - [What is not working] Recognized scan-region for small viewports Apr 30, 2020
@OneDivZero
Copy link
Author

OneDivZero commented Apr 30, 2020

Maybe related to #21 ?

@mebjas mebjas self-assigned this Apr 30, 2020
@mebjas
Copy link
Owner

mebjas commented Apr 30, 2020

In that case I'll fix #21 first and we can see if this is still an issue

@OneDivZero
Copy link
Author

That would be great! Hope you'll find time as soon as possible. Just asking a bit obtrusive, cause the core of my project depends on your solution and I already checked out other libs. But either they are not really maintained and extremely buggy or to complex to integrate (e.g. they require server-side processing which is not an applicable use-case for me).

Just FYI: I'm working on an open-source covid19-project :-)
best regards from germany

@mebjas
Copy link
Owner

mebjas commented May 1, 2020

@OneDivZero I have fixed #21 with a recent push. I have also updated the demo code

Can you validate if it fixes this issue for you?

@mebjas mebjas assigned OneDivZero and unassigned mebjas May 1, 2020
@OneDivZero
Copy link
Author

Yes that looks great ... It works on my iPhone as expected. I will acquire some friends for doing a test on different devices for further confirmation. Thank you!

@mebjas
Copy link
Owner

mebjas commented May 1, 2020

image

Validated to work fine on IPhone 7, Safari browser. Unfortunately only safari is supported on iphone due to issue in Webkit for ios

@mebjas
Copy link
Owner

mebjas commented May 1, 2020

Thanks for confirmation!

@mebjas
Copy link
Owner

mebjas commented May 3, 2020

@OneDivZero Closing this issue, feel free to reopen if this is found in some other device/browser or create a new issue.

@mebjas mebjas closed this as completed May 3, 2020
@OneDivZero
Copy link
Author

OneDivZero commented May 3, 2020

kk ... will share my test-results in a new issue

btw: I picked up the latest script (2 days ago) from github, but I don't see the nice green edges?

@mebjas
Copy link
Owner

mebjas commented May 5, 2020

@OneDivZero - Can you check for console logs, the white/green edges should be visible if there is enough region left in the viewfinder to render based on width and the qrbox size configured.

Also, since looking for logs in mobile devices is harder, I was thinking if I should add a debug option which somehow makes more logs / error visible.

What do you think?

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

No branches or pull requests

2 participants