Commit e627161e authored by Jérome Perrin's avatar Jérome Perrin Committed by Arnaud Fontaine

erp5_safeimage: When zoomify'ing image, quality above 95 should be avoided (pillow library).

parent 4c323863
......@@ -181,7 +181,9 @@ class ZoomifyBase:
if imageRow.mode != 'RGB':
imageRow = imageRow.convert('RGB')
imageRow.save(os.path.join(tempfile.gettempdir(), saveFilename),
'JPEG', quality=100)
# see https://pillow.readthedocs.io/en/stable/handbook/image-file-formats.html#jpeg-saving
# for quality, Values above 95 should be avoided;
'JPEG', quality=95)
if os.path.exists(os.path.join(tempfile.gettempdir(), saveFilename)):
self.processRowImage(tier=tier, row=row)
row += 1
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment