NAME
IIIF::Magick - transform image with IIIF Image API Request using Image Magick
SYNOPSIS
use IIIF::Magick qw(info convert);
my $info = info($file, profile => "level0", id => "...") ;
convert( $request, $file, "target.png" );
DESCRIPTION
This module maps IIIF ImageAPI request parameters to ImageMagick command line arguments. See i3f (command line) and IIIF::ImageAPI (web service) for applications that make use of it.
FUNCTIONS
available
Returns whether ImageMagick is available.
info( $file, id => $id, profile => $profile )
Returns image information object with fields @context, type, protocol, width, and height. Fields id and profile must be added for full IIIF compliance.
convert( $request, $file, $output )
Convert an image file as specified with a IIIF::Request into an output file. Returns true on success.
args( $request, $file )
Get the list of command line arguments to convert to transform an image file as specified via a IIIF::Request.
command( $command, @arguments )
Get call to an ImageMagick command (e.g. convert) with shell-quoted arguments.