Commit 0530d7df authored by hydrargyrum's avatar hydrargyrum

qr-shot: fix python3 incompatibility when decoding image

Image data was not of the right type, preventing the QR decoding from
parent 0dee74e5
......@@ -41,7 +41,7 @@ def decodeImage(qpix):
import PIL.Image
pilimage =
pilimage = pilimage.convert('L')
rawbytes = ''.join(map(chr, pilimage.getdata()))
rawbytes = pilimage.tobytes()
import zbar
zimage = zbar.Image(qpix.width(), qpix.height(), 'Y800', rawbytes)
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment