mirror of
https://github.com/python-pillow/Pillow.git
synced 2025-08-09 06:44:45 +03:00
Floor division fix
Oops #py3
This commit is contained in:
parent
907ac614f0
commit
93e6c08d30
|
@ -207,7 +207,7 @@ def autocontrast_preserve(image, cutoff=0, ignore=None):
|
|||
else:
|
||||
scale = 255.0 / (hi - lo)
|
||||
offset = -lo * scale
|
||||
for layer in range(len(histogram) / 256):
|
||||
for layer in range(len(histogram) // 256):
|
||||
for ix in range(256):
|
||||
ix = int(ix * scale + offset)
|
||||
if ix < 0:
|
||||
|
|
Loading…
Reference in New Issue
Block a user