[Document Scanner bug] Low document resolution on some Samsung devices (including A32)
Describe the bug Taken document photo is in really low resolution (i.e. 976x1346) instead of something like (3000x4000) for some phones. This is happens probably because of the bug in CameraX library used by Document Scanner: https://issuetracker.google.com/issues/162121234?pli=1
Assuming this is it, a library dependency update should do the trick.
To Reproduce Acquire a document using Document scanner.
Expected behavior Document resolution should be way higher, something like 3000x4000.
SDK Info:
- SDK ML Document Scanner 16.0.0-beta1
Smartphone:
- Device/Simulator: Samsung A32
Thanks for flagging.
Did you observe this issue, when the document was almost covering the full portion of the camera viewfinder?
@mebjas Yes, sure. Attached are photos from a Pixel 6a and A32. Notice the difference in resolution and how bad the A32's one is. I'm pretty sure that's the issue I've mentioned.
What is the first and second image in this case?
First is taken with Samsung A32 while the second (better one) is taken with a Pixel 6a. Same document was scanned and in both cases the document occupied most of the area of viewfinder.
Also note that main camera on A32 is a 64 MP one.
Same issue on different real devices, the package was working fine before but now I face the same issue
From our testing, it seems that on devices with several rear-facing cameras, ML-Kit is picking the wrong one in some cases. We can reproduce 100% on Samsung Galaxy Tab Active 3 and Active 5 devices. The result is we need to put the devices about 18 inches away to get the whole page, and the result is grainy and poor quality. Other document scanning SDKs perform much better on these devices, whereas on my Galaxy phone, we can come in much closer to the page and get excellent results. I have looked for a way to override the camera selection in ML-Kit but haven't found anything usable. Hoping for a fix from Google.