What is the point of ZXing.BarcodeWriter in a Xamarin PCL?

Viewed 293

I've tried implementing a Xamarin.Forms function to set the source of an Image using ZXing, similar to: ZXing QR Code Generation in Xamarin Forms PCL

I've read a number of threads on Github and Xamarin Forums where people have attempted the same and are having the same issue as me: ending up with a blank image, despite the byte array returned by BarcodeWriter.Write seemingly having stuff in there.

And the usual resolution to all these threads ends up being using the ZXing.Mobile together with a dependency service to provide platform specific functions instead (with the exception of Allister, who claims to have it working using a ContentView on Android at https://forums.xamarin.com/discussion/47861/zxing-net-mobile-barcodewriter-in-xamarin-forms-pcl).

So my question is: What even is the point of the ZXing common library? Can the byte array returned from BarcodeWriter.Write be used to actually produce an image? Perhaps by passing it through some platform specific function?

I'm sure I'll end up going down the platform specific route myself, but I need to know why the last few hours of my day have gone to waste battling this issue.

0 Answers
Related