Tobias Kremer
and 1 contributors

NAME

Template::Plugin::Imager - Plugin interface to Imager

SYNOPSIS

    [% 
        FILTER null;
            USE im = Imager();
            im.read( 'file', 't/testimage.jpg' );
            im.convert( 'preset', 'noalpha' );
            thumb_im = im.scale( 'xpixels', 32 );
            thumb_im.write( 'file', 't/scaledimage.jpg' );
            im.read( 'file', 't/scaledimage.jpg' );
        END;
        im.getwidth();
    -%]

DESCRIPTION

This module provides an interface to the Imager library. See Imager for a complete description of the Imager library.

Be aware that due to Template::Toolkit merging named parameters into hashrefs while Imager's methods expect hash parameters you have to pass parameters in list form! So when you'd normally do this:

    $im->read( file => 'imager.jpg' );

you'll have to call read() like this in your templates:

    imager.read( 'file', 'imager.jpg' );

AUTHOR

Tobias Kremer, tobias@funkreich.de

SEE ALSO

Imager, Template

COPYRIGHT

Copyright (C) 2009 Tobias Kremer.

This module is free software; you can redistribute it and/or modify it under the same terms as Perl itself.