JimmyPun610 / BarcodeScanner.Mobile

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

Xamarin bindings for text recognition #151

Open aneesh25 opened 1 year ago

aneesh25 commented 1 year ago

I was using your old library Barcode.XF with Xamarin.Firebase.iOS.MLKIT nuget package. Here, I was able to scan barcodes, as well as recognize Text with the below methods

VisionBarcode[] barcodes = await barcodeDetector.DetectAsync(image);
VisionText txt = await textRecognizer.ProcessImageAsync(image);

Both the barcode and text detectors were available.

Now, I have upgraded to your latest library BarcodeScanner.Mobile, where I am able to scan barcode quickly (way better than before), but I don't see any methods for text recognition.I understand you are adding Xamarin.MLKit.iOS.BarcodeScanning bindings, without firebase. But is there a way I can use Text recognition too. (btw, I am trying to scan barcodes and OCR simultaneously).

What I did was, I used your latest library for barcode scanning, and for text recognition, I added Xamarin.Firebase.iOS.MLKIT (0.19). Here I do get the Text detectors, but when i compile the project, I get linking errors

Screenshot 2022-11-02 at 4 18 21 PM
JimmyPun610 commented 8 months ago

merged pull request #190

the function is provided on Maui