Project

General

Profile

Actions

Bug #91855

closed

Image with crop set is JPEG compressed twice

Added by Christian Toffolo over 3 years ago. Updated 17 days ago.

Status:
Resolved
Priority:
Should have
Assignee:
-
Category:
Image Generation / GIFBUILDER
Target version:
-
Start date:
2020-07-23
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
10
PHP Version:
7.2
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

Image with crop set is JPEG compressed twice so it loses quality 2 times based on jpg_quality setting.

1st compress when crop is executed: https://github.com/TYPO3/TYPO3.CMS/blob/5275e76e4ae7e00a0bce59b8d458e547e427b92b/typo3/sysext/core/Classes/Resource/Processing/LocalCropScaleMaskHelper.php#L87
2nd compress when scaling is executed:
https://github.com/TYPO3/TYPO3.CMS/blob/5275e76e4ae7e00a0bce59b8d458e547e427b92b/typo3/sysext/core/Classes/Resource/Processing/LocalCropScaleMaskHelper.php#L118

A solution could be to use a $jpegQuality=100 the first time it's compressed if it will be compressed a second time (using the configured jpg_quality).


Files

5y1nX.png (248 KB) 5y1nX.png Oleg Karun, 2021-01-12 10:10

Related issues 6 (0 open6 closed)

Related to TYPO3 Core - Bug #81796: LocalCropScaleMaskHelper does not respect quality settingClosed2017-07-05

Actions
Related to TYPO3 Core - Bug #93085: Image Select and Image Cropping incorrect after TYPO3 update to v10.4.11Closed2020-12-16

Actions
Related to TYPO3 Core - Bug #93090: Image Cropping broken since TYPO3 10.4.11 releaseClosed2020-12-16

Actions
Related to TYPO3 Core - Bug #93086: Distorted images in FE and BE after the update to 10.4.11Closed2020-12-16

Actions
Related to TYPO3 Core - Bug #93092: Weird visualization of thumbnails in CE after upgrading to 10.4.11Closed2020-12-16

Actions
Precedes TYPO3 Core - Bug #93139: Revert image processingClosedBenni Mack2020-07-242020-07-24

Actions
Actions

Also available in: Atom PDF