[TYPO3-english] grayscale images (with colored mask) )for tt_content
Thomas Hirt
info at thomas-hirt.at
Sun Feb 22 21:44:07 CET 2009
Hi Tomas,
I could solve the problem.
Now every image from tt_content is transformed and lightbox is working.
See the code below.
What I really would like to learn is: Add a new option to tt_content element so that the user can choose if he whants
that transformation.
I could not use 'ig_conf_editor' extension. It throws an error in my installation.
Probably because the PHP version is not high enough.
What would be the basic steps to add this new option?
Do I have to make an extension with the kickstarter?
Probaly i would have the ask if a checkbox was set with a condition?
Thanks,
Thomas
tt_content.image.20.1.file >
tt_content.image.20.1.file = GIFBUILDER
tt_content.image.20.1.file {
XY = [10.w],[10.h]
10 = IMAGE
10.file.import.current = 1
10.file.width.field = imagewidth
20 = EFFECT
20.value = gray | gamma=2.0
30 = IMAGE
30.offset = 0,0
# this is just a blue png (600 x 600 Pixels wide)
30.file = {$path}bilder/overlay.png
# this is the mask,
#the darker it is the less blue will be in the image (600 x 600 Pixels wide)
30.mask = {$path}bilder/mask.png
}
tt_content.image.20.1.imageLinkWrap = 1
tt_content.image.20.1.imageLinkWrap {
enable = 1
typolink.parameter.cObject = IMG_RESOURCE
typolink.parameter.cObject.file {
import.current = 1
maxW = 880
maxH = 580
}
typolink.ATagParams = rel="lightbox"
}
Tomas Mrozek schrieb:
>> 1. Change the .image_effects property to whatever Image Magick option
>> you want [3].
>>
>> This could be ok. Where and how can I do this?
>
> The same way you made the changes that you described in your post. Add
> the appropriate definition in your TS setup:
>
> tt_content.image.20.image_effects = -colorspace GRAY -gamma 2.0
>
>
>> 2. Add new Image Magick option to that property by simply wrapping it
>> as .image_effects is stdWrap.
>>
>> This would be even better. But how could this work?
>
> tt_content.image.20.image_effects.noTrimWrap = || -colorspace GRAY
> -gamma 2.0|
>
>
> Tomas Mrozek
> --
> PS: Yet again, I didn't test it. You will have to try yourself whether
> it works.
> PS 2: Use TypoScript Object Browser to explore currently set TypoScript
> values. It helps a lot!
More information about the TYPO3-english
mailing list