mirror of
https://github.com/python-pillow/Pillow.git
synced 2025-01-27 01:34:24 +03:00
If primary image is already destination size, do not duplicate
This commit is contained in:
parent
5ce67cd896
commit
268be11be6
|
@ -56,7 +56,9 @@ def _save(im, fp, filename):
|
|||
fp.write(o16(len(sizes))) # idCount(2)
|
||||
offset = fp.tell() + len(sizes) * 16
|
||||
bmp = im.encoderinfo.get("bitmap_format") == "bmp"
|
||||
provided_images = {im.size: im for im in im.encoderinfo.get("append_images", [])}
|
||||
provided_images = {
|
||||
im.size: im for im in [im] + im.encoderinfo.get("append_images", [])
|
||||
}
|
||||
for size in sizes:
|
||||
width, height = size
|
||||
# 0 means 256
|
||||
|
|
Loading…
Reference in New Issue
Block a user