Page 1 of 1

beginer's question~ about image size

Posted: 2006-03-28T14:04:16-07:00
by ycul
I need to convert some tiff images with Group4 compression, and scale the image to fit 5800*5800.

I did this....

$x = $image->Set(compression=>'Group4');
warn "$x" if "$x";
$x = $image->Scale(width=>$newW, height=>$newH);
warn "$x" if "$x";

the image I got was scales to the right size, but the file size is HUGE, turns from 150K to 50MB!

Plus the image's compression is still none.

Thanks.

Posted: 2006-03-28T14:26:21-07:00
by magick
Scale() introduces new colors so the image is no longer monochrome, a requirement for Group4 compression. Instead, use Sample() which does not introduce new colors.

thanx

Posted: 2006-03-29T09:38:31-07:00
by ycul
very helpful! Thanx