Jump to content

Ocs-server/Gfx4/Image processing

From KDE Community Wiki
Revision as of 16:05, 28 July 2015 by Snizzo (talk | contribs) (Created page with "There is a very primitive class that abstacts images called EImage. Makes a thumbnail mantaining the aspect ratio. $maxwidth and $maxheight are just the limits. '''WARNING'''...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

There is a very primitive class that abstacts images called EImage.

Makes a thumbnail mantaining the aspect ratio. $maxwidth and $maxheight are just the limits. WARNING: works only with JPG or PNG and requires php-gd server extension.

  • EImage::make_thumbnail($from,$to,$maxwidth,$maxheight) -> Makes a thumbnail using $from as origin file, $to as destination and $maxwidth and $maxheight as width and height limits. Keeps proportions untouched.