NAME

Labyrinth::DIUtils::GD - Digital Image utilities driver with GD for Labyrinth Framework.

SYNOPSIS

use Labyrinth::DIUtils::GD;

Labyrinth::DIUtils::Tool('GD');

my $hook = Labyrinth::DIUtils::GD->new($file);
my $hook = $hook->rotate($degrees);       # 90, 180, 270
my $hook = $hook->reduce($xmax,$ymax);
my $hook = $hook->thumb($thumbnail,$square);

DESCRIPTION

Handles the driver software for GD image manipulation; Do not use this module directly, access via Labyrinth::DIUtils.

METHODS

Contructor

new($file)

The constructor. Passed a single mandatory argument, which is then used as the image file for all image manipulation.

Image Manipulation

rotate($degrees)

Object Method. Passed a single mandatory argument, which is then used to turn the image file the number of degrees specified.

Note that GD doesn't support rotating angles other than 90, 180 and 270.

reduce($xmax,$ymax)

Object Method. Passed a two arguments (defaulting to 100x100), which is then used to reduce the image to a size that fit inside a box of the specified dimensions.

thumb($thumbnail,$square)

Object Method. Passed two arguments, the first being the name of the thumbnail file to be created, and the second being a single dimension of the square box (defaulting to 100), which is then used to reduce the image to a thumbnail.

SEE ALSO

GD, Labyrinth, Labyrinth::DIUtils::ImageMagick

AUTHOR

Barbie, <barbie@missbarbell.co.uk> for Miss Barbell Productions, http://www.missbarbell.co.uk/

COPYRIGHT & LICENSE

Copyright (C) 2002-2014 Barbie for Miss Barbell Productions
All Rights Reserved.

This module is free software; you can redistribute it and/or
modify it under the Artistic License 2.0.