Spent almost a day searching but couldn't find a proper solution. I am developing a QR reading module for my win 8.1 phone app which is Silverlight based (not win 8.1 phone native)
I am using zxing lib to add complete the QR module. I have reached the point where I have the image from the camera (MediaCapture) which of object WriteableBitmap and I want to use the api QRCodeReader.decode(BinaryBitmap bb).
I have tried using RGBLuminanceSource as stated by most articles but that works in native app (as it needs reference to System.Windows which is not valid for Silverlight based apps.
Can someone guide me on converting WriteableBitmap to BinaryBitmap?
I've used the following code on pre window phone 8.1 with zxing using the PhotoCamera class. Now I'm not sure if this is still valid for you purposes but here is the
LuminanceSourcederived class.That is then used like this.
where
_luminanceis of typePhotoCameraLuminanceSource