From cc8481c50cc304d8086c430e2ea1628806cfefb0 Mon Sep 17 00:00:00 2001 From: alxf Date: Mon, 2 Oct 2017 01:16:54 +0200 Subject: [PATCH] Fix deprecated call to pil method --- python/examples/img2txt.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/python/examples/img2txt.py b/python/examples/img2txt.py index a7e95db..dbee097 100755 --- a/python/examples/img2txt.py +++ b/python/examples/img2txt.py @@ -224,7 +224,7 @@ def main(): dit.set_charset(charset) #create dither - dit.bitmap(cv, 0, 0, width, height, img.tostring()) + dit.bitmap(cv, 0, 0, width, height, str(img.tobytes())) #print export to screen sys.stdout.write("%s" % cv.export_to_memory(exformat))