Pillow/docs/releasenotes/5.4.0.rst

28 lines
622 B
ReStructuredText
Raw Normal View History

2018-10-18 10:58:20 +03:00
5.4.0 (unreleased)
-----
API Changes
===========
Negative indexes in pixel access
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
When accessing individual image pixels, negative indexes are now also accepted.
For example, to get or set the farthest pixel in the lower right of an image::
px = im.load()
print(px[-1, -1])
px[-1, -1] = (0, 0, 0)
2018-10-18 10:58:20 +03:00
Other Changes
=============
ImageOps.fit
^^^^^^^^^^^^
2018-10-18 11:40:32 +03:00
Now uses one resize operation with ``box`` parameter internally
instead of a crop and scale operations sequence.
2018-10-18 10:58:20 +03:00
This improves the performance and accuracy of cropping since
2018-10-18 11:40:32 +03:00
the ``box`` parameter accepts float values.