How to make Google Mobile Vision to continuously trying to auto focus? - android

I'm using ML Kit. I'm trying to achieve the behavior where my barcode scanner Android app keeps trying to focus the camera while I move when trying to find a barcode. You know, the typical "clear-blur" behavior that we get when trying to use our phone camera to take a photo.
What are the settings I should turn on?

Related

Taking a photo without preview in android

I'm learning android studio and I'm currently working on a robotics project in which an Android phone is placed on the robot and used as the processor, therefore I can't reach the phone by hand. The phone needs to do some image processing. And it's not a real-time processing so I need to take a photo (Preferably Bitmap) whenever I want, quickly and without preview and confirmation. I've tried some tutorials and they all open the camera app and the user needs to capture and then confirm the photo.
I don't have problem with the processing and I don't need to use openCV etc. I just need help with capturing the photo. Thanks
You can implement your own camera, either via the camera APIs (hard) or by using a library (CameraKit-Android, Fotoapparat, etc.), thank you will have control, you can directly save the image without previewing it

Zebra scanner emdk integration

I am adding zebra scanning sdk to my app. I see that when camera is open, the hardware scanner does not work. I have implemented Scanner.StatusListener but I see that this is not invoked when camera is open. I am seeing a way to know when user clicks the hardware button when camera is open to show them a toast. How can I get that callback
Unfortunately it is not possible to use both the camera and the scanner within the same app because of a low level hardware dependency (even if you are using the 2D imager for scanning, rather than the camera, this hardware dependency exists). There is no easy way to programmatically determine that the user has pressed the trigger in this scenario, to display the toast as you say, the only way I can think of would be for your app to remap the trigger to some other action using the KeyMapping Manager and then revert the trigger back to its original behaviour when the camera is dismissed. Rather than try to manage the EMDK enabling & disabling when the camera is used I would recommend using DataWedge for scanning in your app, you still can't do scanning when the camera is displayed but it should make your application logic simpler

Android Photo Scanning

I am looking to develop an application that will allow the user to launch the camera and use it to scan what the camera sees for a certain logo or word.
I have had some experience using the Zebra barcode scanning library so I am able to launch the camera and scan for a barcode fine.
The issue comes when I try to scan for a logo. Is it at all possible to scan for the logo in real time with the camera or would I have to have the user take picture and then scan the newly take picture and compare it with the logo that is being searched for?
Scanning for a logo is an entirely different problem. The Zebra Library has been designed specifically to recognized barcodes and qr codes anything outside of that scope and it won't be able to interpret anything. You can scan for logos in real time or on the cloud. Amazon does this with their shopping application so that you can research what you find at the supermarket or at a friends house.
There are companies that can offer you Image Recognition as a Service:
https://www.clarifai.com
or you can look into your own open source implementation
opencv.org/
There's examples for OpenCV for Android but you're going to need a bit of background on Machine Learning and Computer Vision before you get started.

Android Camera Hardware zoom

we are developing an Android App to be used on 1 of 2 Android cameras. Specifically the Nikon S800C.
We are able to use digital zoom but as yet we have not found a way of handling the hardware zoom which is the whole point of using a camera rather than a basic smart phone.
We cannot use the internal camera app as we have to make a custom camera overlay and preview screen. As such we have had to compose our own camera app.
It seems from what I have been advised it is not technically possible to control the camera hardware zoom from within our own app.
So my question is: Is this really the case? Is there absolutely no way of building a custom camera app that has a custom camera capture experience and also a camera HARDWARE zoom?
If this is the case, is there a way of creating a custom preview and camera overlay screen for the existing internal camera app on our device? Which would negate the need to build our own.
Thanks.

Can I control the flashlight without using android.hardware.Camera?

The use of front light option with zxing1.6 barcode scanner does not work on my Nexus One. I need to be able to use the flashlight in my app, but you can't have two instances of the camera running. Is there a way to use the flashlight without accessing the camera? Or can I somehow access a camera that is already in use?
I am using the Google IntentIntegrator.java patch to be able to scan barcodes.
The short answer is "no"; the front LED is controlled as a flash mode, which is a property of the camera. It is mode "torch". And no two apps can't open the camera at the same time.
(A longer answer is that there used to be a hidden API for this, which is what Barcode Scanner tries to access, but it doesn't work on almost any device anymore. You can dig into the source code to see FlashlightManager.)
Since Android 2.x there is this proper API for turning on the light, and the beta of the next version of Barcode Scanner does use it. You can try it here.

Categories

Resources