NAME

Imager::Tiler - package to aggregate images into a single tiled image via Imager

SYNOPSIS

use Imager::Tiler qw(tile);
#
#   use computed coordinates for layout, and retrieve the
#   coordinates for later use (as imported method)
#
my ($img, @coords) = tile(
    Images => [ 'chart1.png', 'chart2.png', 'chart3.png', 'chart4.png'],
    Background => 'lgray',
    Center => 1,
    VEdgeMargin => 10,
    HEdgeMargin => 10,
    VTileMargin => 5,
    HTileMargin => 5);
#
#   use explicit coordinates for layout (as class method)
#
my $explimg = Imager::Tiler->tile(
    Images => [ 'chart1.png', 'chart2.png', 'chart3.png', 'chart4.png'],
    Background => 'lgray',
    Width => 500,
    Height => 500,
    Coordinates => [
        10, 10,
        120, 10,
        10, 120,
        120, 120 ]);

DESCRIPTION

Creates a new tiled image from a set of input images. Various arguments may be specified to position individual images, or the default behaviors can be used to create an reasonable placement to fill a square image.

METHODS

Only a single method is provided:

$image = Imager::Tiler->tile( %args )

($image, @coords) = Imager::Tiler->tile( %args )

Returns a Imager::Image object of the images specified in %args, positioned according to the directives in %arg. In array context, also returns the list of upper left corner coordinates of each image, so e.g., an application can adjust the image map coordinate values for individual images.

Valid %args are:

SEE ALSO

Imager

REPOSITORY

Fork this module on GitHub: https://github.com/zoffixznet/Imager-Tiler

BUGS

To report bugs or request features, please use https://github.com/zoffixznet/Imager-Tiler/issues

If you can't access GitHub, you can email your request to bug-imager-tiler at rt.cpan.org

MAINTAINER

Zoffix Znet (zoffix 'at' cpan.org)

AUTHOR, COPYRIGHT, and LICENSE

Dean Arnold mailto:darnold@presicient.com

Copyright(C) 2007, 2008, Dean Arnold, Presicient Corp., USA.

Permission is granted to use, copy, modify, and redistribute this software under the terms of the Academic Free License version 3.0, as specified at the Open Source Initiative website http://www.opensource.org/licenses/afl-3.0.php.