BlinkID / blinkid-android

Everything you need to add AI-driven ID scanning into your native Android app.
https://microblink.com/identity/identity-document-scanning/
438 stars 153 forks source link

Can't open camera with Device that only back facing camera #200

Closed chenrina168 closed 4 years ago

chenrina168 commented 4 years ago

Hello team, When i use the sdk with device have only back facing camera , the camera is not open. I try set camera type to default type. it's still not work.

Do you have any solution for this issue ?

eddieAvdg commented 4 years ago

Hello, Could you please provide us some more details about the device you're using? Since there is only one camera, it might actually be classified as frontside, you can try changing the settings the following way: https://blinkid.github.io/blinkid-android/com/microblink/uisettings/CameraSettings.Builder.html#setType-com.microblink.hardware.camera.CameraType-

chenrina168 commented 4 years ago

I use wizarPOS Q2 device. I already set camera setting , But It seem like error like previous time. The error : E/RecognizerRunnerView.java:501@Camera1: Exception caught on camera startup java.lang.RuntimeException: Fail to connect to camera service.

culoi commented 4 years ago

Hi @Rina2001

I suggest that you test with our DirectAPI sample that has a custom camera solution. https://github.com/BlinkID/blinkid-android/tree/master/BlinkIDSample/BlinkID-DirectApiSample

Maybe this will resolve the issue with connecting to camera service.

Regards,

Ivan

chenrina168 commented 4 years ago

Dear @Ivan Let me try to run with your sample API again Best regard, Rina

chenrina168 commented 4 years ago

Ok , it's worked, thank you.