Open dpolivy opened 11 months ago
Hi @dpolivy I am open to merge that one and release a new version. I find that one genuinely helpful.
Two remarks:
Thanks for the changes!
Hi @benjohnde, I can fix up the Podspec URL. On iOS 13, I have to ask, is there really any valid reason to support anything less than iOS 13 at this point? Looking at this chart (https://iosref.com/ios) you only really lose iPhone 6/6Plus and some older iPads that can't support iOS 13.
One point of documentation I should add to this PR is that the ultra wide camera only seems to really work for barcode scanning on iPhone 13 Pro/Pro Max and higher Pro/Pro Max models. Other models with an ultra wide camera don't seem to work very well based on my testing. I "hacked" this into my app logic that uses this library, and it might be useful for future consumers to know this. (Originally my logic enabled ultra wide if it existed, but it caused 11 Pro/12 Pro devices to not be able to scan anything.)
Hi @benjohnde, I can fix up the Podspec URL. On iOS 13, I have to ask, is there really any valid reason to support anything less than iOS 13 at this point? Looking at this chart (https://iosref.com/ios) you only really lose iPhone 6/6Plus and some older iPads that can't support iOS 13.
One point of documentation I should add to this PR is that the ultra wide camera only seems to really work for barcode scanning on iPhone 13 Pro/Pro Max and higher Pro/Pro Max models. Other models with an ultra wide camera don't seem to work very well based on my testing. I "hacked" this into my app logic that uses this library, and it might be useful for future consumers to know this. (Originally my logic enabled ultra wide if it existed, but it caused 11 Pro/12 Pro devices to not be able to scan anything.)
Appreciate your comment and work. This library is fairly old and if there is a way to stay at the minimum supporting level without sacrificing the support of newer devices, I would rather add a few lines, although I agree that probably a minority at max will benefit from that.
I realize this repo is essentially dead, but I am opening this PR in the hopes that others may find it useful. We've had a lot of reports of users on modern iPhones having trouble scanning barcodes because the camera won't focus close-in. To address this, I've added a flag that will tell the library to try to use the ultra wide camera if available. If not, it will fall back to the regular wide camera.
I also updated the minimum iOS version to 13 to make it easier to add this code.
If you don't want to mess around with forks and want to consume this, I have a private Podspec repo available here that you can reference the Cocoapod from: