unable to create bmp images with 256 colors / 8 bit

Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
Post Reply
Jens

unable to create bmp images with 256 colors / 8 bit

Post by Jens »

Hi

I would like to create a BMP image for a Cisco IP phone, which only supports 8bit bmp images but I unable to create or convert an image into a matching format.

I'm using the version "ImageMagick 6.3.9 03/02/08 Q16".

My tests are ending in getting different versions of my image bitmap. I have got PseudoClass and DirectClass images bit 32, 24 or 4 bit but never with 8 bit as it has to be.

Can some help me please with this issue?
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: unable to create bmp images with 256 colors / 8 bit

Post by fmw42 »

try

convert <infile> -depth 8 <outfile.bmp>

or post your command attempts for us to review.

Also what type of input images are you starting with? Post a link to an example!
Jens

Re: unable to create bmp images with 256 colors / 8 bit

Post by Jens »

Done.

I have converted the gif file weather.gif GIF 90x56 90x56+0+0 PseudoClass 64c 8-bit 800b
into the bmp file weather1.bmp BMP 90x56 90x56+0+0 PseudoClass 256c 8-bit 3kb

Here is a reference image, how it should be: weather2.bmp BMP 90x56 90x56+0+0 PseudoClass 217c 8-bit 5.93359kb.
I have generated this image with PhotoShop, using the "web colors" color table, 8 bit and without RLE.

Thanks a lot for your help ...
User avatar
anthony
Posts: 8883
Joined: 2004-05-31T19:27:03-07:00
Authentication code: 8675308
Location: Brisbane, Australia

Re: unable to create bmp images with 256 colors / 8 bit

Post by anthony »

If you want 'web colors' try

Code: Select all

-map netscape:
just before writing out the image.

See http://imagemagick.org/Usage/quantize/#web_safe for more detail. Especially note the discussion that follows, and the links to more information about this color palette.
Anthony Thyssen -- Webmaster for ImageMagick Example Pages
https://imagemagick.org/Usage/
Post Reply