Page 1 of 1

can't change depth to 8bit in png

Posted: 2010-04-06T10:15:20-07:00
by dkudelko
Hi!
Try to convert png image fromn 24bit or 32bit depth to 8bit depth, but convert.exe no return 8bit depth result.
Use ImageMagick-6.6.0-Q16 win32
And my command is like

Code: Select all

convert -colors 255 -depth 8 testimage.png testimage8bit.png
But in in ImageMagick-6.4.9-4-Q16- win32 the command works.

Have anybody a same problem? Any idea how resolve/fix it or why?

Thanks!

Re: can't change depth to 8bit in png

Posted: 2010-04-06T10:26:01-07:00
by snibgo
The options are in the wrong order. Try:

convert testimage.png -colors 255 -depth 8 testimage8bit.png
or
convert testimage.png -colors 255 -depth 8 -type Palette testimage8bit.png

See http://www.imagemagick.org/Usage/formats/

Re: can't change depth to 8bit in png

Posted: 2010-04-06T10:29:37-07:00
by fmw42
try adding -type palette for 24 to 8 bits or -type palettematte for 32 to 8bits with alpha

see also -define png:color-type=2
http://www.imagemagick.org/Usage/formats/#png

and

viewtopic.php?f=3&t=15445

and

viewtopic.php?f=1&t=15584&start=15

Re: can't change depth to 8bit in png

Posted: 2010-04-09T00:35:52-07:00
by dkudelko
thanks you all, i'll try