On Wed, 13 May 2009, Stefan Kilp [sk-software] wrote: > i try to crop a square from the middle of a picture (mostly it is the > important part). > the square is needed for a thumb list. > > example ( a 80x80 square form the middle of an image) > > image 200x200 -> crop 60,60 80x80 > > image 300x1000 -> crop 110, 460 dim 80x80 > > image 100 x 20 -> crop 10,0 80x20 > > the problem is that the parameter for the filter has to be defined before the > image is > processed. so right now i have to get the image size, define a filter, get > next image, get > imagesize, define filter, and so on. > > thats why i was asking for a kind of callback function for the filter so i > can define crop > dynamicly
Ah, we have a specific function for this, the "filledThumbnail" filter: http://ezcomponents.org/docs/tutorials/ImageConversion#creating-thumbnails and http://ezcomponents.org/docs/api/trunk/ImageConversion/ezcImageThumbnailFilters.html regards, -- Derick Rethans eZ components Product Manager eZ systems | http://ez.no -- Components mailing list Components@lists.ez.no http://lists.ez.no/mailman/listinfo/components