http://qs1969.pair.com?node_id=441287


in reply to Re: Re: Image::Magick
in thread Image::Magick

I am trying to increase the number of colors in an image, but it is not working.
$img = Image::Magick->new; $img->Read('../images/logo.gif'); my $nu = $img->Get('colors'); $img->Set(colors=>256); $img->Quantize(); my $nu1 = $img->Get('colors');
nu and nu1 remains the same- 127 in my case. Any help is appriciated.

Replies are listed 'Best First'.
Re: Image::Magick Quantize
by Roy Johnson (Monsignor) on Mar 21, 2005 at 20:26 UTC
    Why do you want to increase the number of colors in the image? What new colors do you think ImageMagick should add, and where do you think it should put them?

    Caution: Contents may have been coded under pressure.
      Actually, I am trying to print/display an image on the pdf file. Using: my $image = PDF_load_image($p, "gif", "../images/logo.gif",""); but, this function does not support less than 128 colors. Is there is any other thing I can do to display an image to PDF file? Thanks for your help.
        I would recommend converting the file to some other format. What does PDF_load_image accept?

        Caution: Contents may have been coded under pressure.