-
Notifications
You must be signed in to change notification settings - Fork 370
Adjusting focus for iPhone 6 / 6 Plus #22
Comments
As @dgoldman-ebay has commented elsewhere, card.io was designed to scan, not to take sharp images. In general, determining absolutely whether an image is in focus is a very hard problem. We do a very crude approximation to this with our focus score calculation, which is probably what you want to look at if, you want to just try fiddling with some thresholds. Other options include attempting to monitor focus scores over time, waiting for them to stabilize (with hysteresis), in the hopes that that indicates that the camera has finished focusing. Or perhaps best of all, dig into the camera APIs. I seem to recall that in recent iOS versions, there's a newly-added ability to set the focal depth programatically. It might have to be set per-device, but this could entirely circumvent the entire issue. Please do experiment with a wide range of lighting conditions and cards. We found that focus scores and related metrics tend to vary greatly...which is why the emphasis was placed on being able to scan blurry cards. :) |
We're already using the iOS 8 added It will take a bit of experimenting with the I'm almost talking myself into coding this myself! But I really don't have the time these days. |
See also #21. Maybe you two can work on this together? |
Hi there.
I've noticed that Card.IO has a tendency to take a photo too quickly on the iPhone 6 & 6 Plus. Not sure if this is due to the camera quality or the SDK detecting edges that don't belong to the card, but it's leading to photos that are unfocused.
I had a look at CardIOGuideLayer.mm, and wondered if upping the float values being used in the 'setVideoFrame:videoFrame' method (line 469) would help make the SDK wait before the user has their card fully focused in the frame. Anywhere else I should considering looking?
Thanks in advance.
The text was updated successfully, but these errors were encountered: