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

Scanning View is a little tweak/squeezed on Android devices #903

Closed
SunshineSpring666 opened this issue May 21, 2020 · 2 comments
Closed

Comments

@SunshineSpring666
Copy link

After calling await scanner.Scan(options); I got a squeezed camera view.
I tried it on several android devices but they all look that way. Are there any workaround or options to fix this?
Thanks.
微信图片_20200521182857

@nitewulf
Copy link

Hey sunshine,

I just submitted a PR that calculates a more accurate display resolution. It's here:
#906

It still won't be perfect because of how long the phone is, but it will pick a resolution that is closer to the aspect ratio of that surface view.

Ideally, the camera preview should be zoomed in and cropped a bit. Or, scaled down to fit with black bars on the top/bottom. And make both options configurable. Unfortunately, I couldn't figure out how to do either of those :( Otherwise I think my PR is the best approach at the moment.

@SunshineSpring666
Copy link
Author

Thanks for replying. I'll check the thread later.

Best regards,
Sunshine

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

2 participants