Retain the 8 bit format after rotation

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
User avatar
magick
Site Admin
Posts: 11064
Joined: 2003-05-31T11:32:55-07:00

Post by magick »

Add -colors 256 to your command line to create a colormapped BMP image.
User avatar
anthony
Posts: 8883
Joined: 2004-05-31T19:27:03-07:00
Authentication code: 8675308
Location: Brisbane, Australia

Post by anthony »

If you do not want -rotate to add extra colors to your image, but only use existing colors (some image degrading can occur) then you can use -interpolate nearest-neighbour setting before rotating. This is a new addition to IM and not yet fully documented in IM examples.

Also rather than -colors 256, you can re-map the colors to the original set of colors using
-map original.bmp. For more info on color reduction see the IM examples section of "Color Quantization and Dithering".
Anthony Thyssen -- Webmaster for ImageMagick Example Pages
https://imagemagick.org/Usage/
Post Reply