Image Magick thumbnail batch resizing
am 16.01.2006 12:46:38 von unknownPost removed (X-No-Archive: yes)
Post removed (X-No-Archive: yes)
Spartacus
>
> As both 'convert' and 'display' utilize imagemagick, I guess it should in
> theory be possible to get the same quality either way.
>
> Does anyone knows how the "display vid" procedure acheive such good result,
> and how I can get equivalent quality using a simple batch convert?
I think you want to scale instead of sample
do convert -quality 85 -scale x75 $i ../thumbs/`basename $i .jpg`.jpg;
> Or are there any suitable perl tools (modules) that could be useful
> here?
PerlMagick gives you access to all of ImageMagick from within Perl,
but it doesn't do anything differently.
Alternatively, you could use Image::Resize or GD itself.
I hope this helps,
Tim
Spartacus wrote:
> Or are there any suitable perl tools (modules) that could be useful here?
I'm accessing ImageMagick from the Perl module Image::Magick:
use Image::Magick;
my $image = Image::Magick->new;
$image->Read('/path/to/original/image');
$image->Thumbnail('120x120');
$image->Write('/path/to/thumbnail/directory');
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl