JimmyPun610 / BarcodeScanner.Mobile

Barcode Scanner using GoogleVision API for Xamarin Form, Maui
MIT License
340 stars 100 forks source link

Dark scannerimage #101

Closed SolutionSoftwareMaexx closed 2 years ago

SolutionSoftwareMaexx commented 2 years ago

Hello, I use BarcodeScanner.FX in my app. It always worked very well too. Since about 3 weeks the scanner image is much too dark. In the simulator it works. But on my POCO X3 nfc comes the problem. The example app works fine though. Is another update or another nuget package responsible for this? The last thing I installed was Xamarin.FFimageLoading.Forms. Have also tried it without. I don't know what else I could check. RequestFPS has no influence at all. Greetings Marcel

JimmyPun610 commented 2 years ago

Hi @SolutionSoftwareMaexx,

I do not think it is related to Xamarin.FFImageLoading.Forms, what is the exact problem are you facing?

davidjonsson commented 2 years ago

I have this as well on 6.2.0-pre on Android (have not tried iOS yet). The camera feed is almost completely dark. If I point the camera into a light I can see it just barely.

I have a OnePlus Nord

EDIT: After more testing, the issue manifests itself if setting RequestedFPS on the CameraView in Android (works good on iOS). Dont know if the following stackoverflow can have something to do with it android-camera-preview-is-dark

JimmyPun610 commented 2 years ago

Hi @davidjonsson ,

I only got a Pixel 3 and it is not happening. About RequestFPS, it is for Android only, and it only set on demand. Not sure if below Android source is causing the situation.

https://github.com/JimmyPun610/BarcodeScanner.XF/blob/8e961c0faeecad7fdb92b3a0201f501424bee934/GoogleVisionBarCodeScanner/Android/Renderer/CameraViewRenderer.cs#L92-L99

mantasdaskev commented 2 years ago

Hi, I have a same problem with a latest nuget. I am debugging on Xiaomi 11T (Android 12) and Lenovo Yoga Tab 11 (Android 11) tablet. Preview on both devices are very dimmed. After removing RequestedFPS attribute on both devices preview normalized.

AlessandroLanzoni commented 2 years ago

I have the same problem, I use a Redmi 8 Pro for testing. And same of mantasdaskev, if I remove RequestedFPS image is normal

markuznw commented 2 years ago

Same problem here on Realme RMX3363 on Android 12, same fix (removing RequestedFPS)

JimmyPun610 commented 2 years ago

RequestFPS is required to set only if you have that needs.