Johan,
Firstly thanks for building this library.
Some months ago I wrote a B4A app that scans barcodes, amongst other things.
At the time I used the original ABZXing library:
https://www.b4x.com/android/forum/threads/abzxing-barcode-reader.7303/
One of the main reasons for using this library, rather than one of the "built-in" options, was that the native ZXing app has a unique setting that allows you to set torch mode to auto - meaning that the torch automatically turns on in poor light conditions - an important consideration for my app which will be used in all sorts of light conditions by all sorts of people - some of whom will have great difficulty just holding a phone to allow the barcode to focus let alone toggling a torch on/off.
I subsequently ported the app to B4I - the iBarcode library was equally deficient but I eventually managed to solve this, see:
https://www.b4x.com/android/forum/t...roid-zxing-app-with-full-torch-control.63177/
This B4I app actually uses the camera on the torch side to sense ambient light conditions.
I am now revisiting the original B4A app and have discovered, to my dismay, that the native ZXing app actually uses the light sensor on the screen side of my Samsung S5, not a sensor on the torch side. This can be decidedly less than perfect in certain lighting conditions e.g. where the light source is behind the user forcing him to shadow the barcode by the phone.
I have been playing around with the CameraEx class, as modified by Jim Brown:
https://www.b4x.com/android/forum/t...ibrary-functionality.23801/page-8#post-191819
This has
GetSupportedFlashModes and
get/setFlashMode subs that burrow into the low level code via the Reflections library (way out of my league).
A bit of experimentation with this class on my Samsung S5 with the
Auto flash mode suggests that it is actually turning the torch on when light conditions
on the torch side are poor - which is what I am after.
So my question to you is: how hard would it be to add functionality to your library that adds an
Auto torch capability, possibly similar to the
GetSupportedFlashModes and
get/setFlashMode subs in the CameraEx class?
Thanks in anticipation...