mirror of
https://github.com/python-pillow/Pillow.git
synced 2024-12-25 17:36:18 +03:00
Py3 fixes for ImageQt.align8to32
This commit is contained in:
parent
a5da0e0c4a
commit
6736344703
|
@ -108,10 +108,10 @@ def align8to32(bytes, width, mode):
|
||||||
return bytes
|
return bytes
|
||||||
|
|
||||||
new_data = []
|
new_data = []
|
||||||
for i in range(len(bytes) / bytes_per_line):
|
for i in range(len(bytes) // bytes_per_line):
|
||||||
new_data.append(bytes[i*bytes_per_line:(i+1)*bytes_per_line] + '\x00' * extra_padding)
|
new_data.append(bytes[i*bytes_per_line:(i+1)*bytes_per_line] + b'\x00' * extra_padding)
|
||||||
|
|
||||||
return ''.join(new_data)
|
return b''.join(new_data)
|
||||||
|
|
||||||
def _toqclass_helper(im):
|
def _toqclass_helper(im):
|
||||||
data = None
|
data = None
|
||||||
|
|
Loading…
Reference in New Issue
Block a user