so scheint's zu gehen. Keine Ahnung, ob das "richtiger" ist. Wirkt irgendwie sehr "teuer":
if ($equalHeight) { // Initiate gifbuilder object in order to get dimensions AND calculate the imageWidth's $gifCreator = GeneralUtility::makeInstance('TYPO3\\CMS\\Frontend\\Imaging\\GifBuilder'); $gifCreator->init(); $relations_cols = array(); // contains the individual width of all images after scaling to $equalHeight $imgWidths = array(); $resFactory = GeneralUtility::makeInstance('TYPO3\CMS\Core\Resource\ResourceFactory'); // create instance to storage repository for ($a = 0; $a < $imgCount; $a++) { $imgKey = $a + $imgStart; if (\TYPO3\CMS\Core\Utility\MathUtility::canBeInterpretedAsInteger($imgs[$imgKey])) { $file = $resFactory->getFileObject($imgs[$imgKey]); $fileProps = $file->getProperties(); $origWidth = $fileProps['width']; $origHeight = $fileProps['height']; } else { $totalImagePath = $imgPath . $imgs[$imgKey]; $imgInfo = $gifCreator->getImageDimensions($totalImagePath); $origWidth = $imgInfo[0]; $origHeight = $imgInfo[1]; } $rel = $origHeight / $equalHeight; // if relations is zero, then the addition of this value is omitted as the image is not expected to display because of some error. if ($rel) { $imgWidths[$a] = $origWidth / $rel; // counts the total width of the row with the new height taken into consideration. $relations_cols[(int) floor($a / $colCount)] += $imgWidths[$a]; } } } Die Frage bleibt offen. Geht das so? _______________________________________________ TYPO3-german mailing list TYPO3-german@lists.typo3.org http://lists.typo3.org/cgi-bin/mailman/listinfo/typo3-german