Bug #65378
closed
Scaling/cropping images in GIFBUILDER does not work
Added by Stephan grass about 9 years ago.
Updated about 4 years ago.
Description
I am using following TypoScript to center an image on a specified rectangle.
This will not work after updating to 6.2.10
lib.prodImage = COA
lib.prodImage {
10 = IMAGE
10 {
file = GIFBUILDER
file {
format = jpg
workArea = 0,0,200,200
XY = 200,200
backColor = #ffffff
quality = 95
10 = IMAGE
10 {
file.import.current = 1
file.maxH = 200
file.maxW = 200
align = c,c
}
}
}
}
Files
same here. I'm using gifbuilder to scale images + watermarks etc. Everything was fine in 6.2.9 and is now messed up in 6.2.10
Here is a test-snippet
page = PAGE
page {
config {
no_cache = 1
}
10 = IMAGE
10 {
file = GIFBUILDER
file {
format = jpg
quality = 90
XY = 500,500
10 = IMAGE
10 {
file = fileadmin/template/img/test.jpg
file.width = 500c # HAS NO EFFECT in 6.2.10!
file.height= 500c # HAS NO EFFECT in 6.2.10!
}
}
}
}
OK folks so here is the deal: https://review.typo3.org/#/c/36180/3/typo3/sysext/frontend/Classes/Imaging/GifBuilder.php
$fileInfo3 gets the correctly scaled, processed image while $fileInfo['originalFile']->getForLocalProcessing(FALSE) delivers the original, unscaled image.
So I don't know why this condition was implemented but at least it should rescale the originalFile like the one in $fileInfo3
I have the same problem with any GIFBUILDER configuration after upgrading to 6.2.10 :-|
Attachment to previous bug....
Since TYPO3 6.2.10 I've the same problem like Geddo with GIFBUILDER. The problem occurs with width= and height=, too.
I work with:
- GraphicsMagick 1.3.18 2013-03-10 Q8
- PHP 5.5.9
- Ubuntu 14.04.2 LTS.
- Status changed from New to Under Review
Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/37483
Same here. After upgrading TYPO3 from version 6.2.9 to 6.2.10 the scaling images using GIFBUILDER didn't work. When I'm testing image processing in Instal Tool everything looks ok, byt when I want to change img using GIFBUILDER scaling img didn't work. I'm using GIFBUILDER to adding watermark to yag gallery.
Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/37483
Patch set 3 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/37483
Patch set 4 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/37483
- Subject changed from Typo3 6.2.10 Gifbuilder to Scaling/cropping images in GIFBUILDER does not work
- Target version set to next-patchlevel
- Complexity set to medium
- Is Regression changed from No to Yes
Patch set 5 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/37483
Under php 5.4.34 GifBuilder.php will cause the error:
Parse error: syntax error, unexpected 'class' (T_CLASS), expecting identifier (T_STRING) or variable (T_VARIABLE) or '{' or '$' in /Users/stephangrass/Documents/_Webs_/MR-Chemie/typo3/typo3_src-6.2.10/typo3/sysext/frontend/Classes/Imaging/GifBuilder.php on line 141
@Stephan: I can not confirm your "fatal" report (our test environment would also have found that in travis-ci for php 5.4 on 6.2.10)
Patch set 1 for branch TYPO3_6-2 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/37533
- Status changed from Under Review to Resolved
- % Done changed from 0 to 100
Under php 5.4.34 GifBuilder.php will cause the error:
Same for me wihtin
Parse error: syntax error, unexpected 'class' (T_CLASS), expecting identifier (T_STRING) or variable (T_VARIABLE) or '{' or '$' in /Users/stephangrass/Documents/_Webs_/MR-Chemie/typo3/typo3_src-6.2.10/typo3/sysext/frontend/Classes/Imaging/GifBuilder.php on line 141
This worked for me: 4 or 5 times in this file:
... GeneralUtility::makeInstance('TYPO3\\CMS\\Frontend\\ContentObject\\ContentObjectRenderer');
The applied changeset breaks PHP 5.3.10 too
- Status changed from Resolved to Closed
- Description updated (diff)
Also available in: Atom
PDF