[dev] Horde_Image / polaroid-like stack
Chuck Hagenbuch
chuck at horde.org
Mon Oct 15 19:11:48 UTC 2007
Quoting Michael Rubinsky <mike at theupstairsroom.com>:
> Starting to play around with implementing the "Polaroid style" stack
> (at least using IM or Imagick extension - the gd driver looks like
> it will be pretty tough). Anyway, wanted to throw some ideas out
> there and get some opinions...
>
> 1) Add a type of thumbnailStack() method to Horde_Image_*:
>
> function thumbnailStack($images, $w, $h)
>
> where $images is an array of various sized images, $w, $h are
> dimensions for the thumbnails. The image that the Horde_Image object
> represents will serve as the "desk" image to place the thumbnails on.
>
> 2) Don't implement this in Horde_Image at all - do it in Ansel using
> IM/Imagick extension or if that's not present, revert to a single
> thumbnail like we do now.
I don't think that there should be a Horde_Image::thumbnailStack
method; that seems much too specialized to be part of the Horde_Image
api. If you can break down the necessary operations into generic
Horde_Image::* calls, then you could create a separate object - either
a Horde_Image_Decorator, or some other composite - that made it work.
-chuck
More information about the dev
mailing list