Problem converting JPG to GIF

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?".
User avatar
Posts: 8884
Joined: 2004-05-31T19:27:03-07:00
Authentication code: 8675308
Location: Brisbane, Australia

Post by anthony »

Of course opening GIF in photoshop shows it as an indexed color.


That is the nature of GIF images. A power of 2 sized color index table, with 256 colors as the absolute upper limit. Also one color index can be declared as being a transparent color, which means you can only get boolean or on/off transparency.

For animations GIF can use either a single global color table, or a separate color table for each frame of the image. This last makes GIF animation optimization really painful!

JPEG images on the other hand use direct 24 bit RGB colors. No color index tables at all. However it is lossy and some individual pixel colors may not read exactally the same as the color that you saved it as.

PNG can do either GIF style color tables, or JPEG style direct colors, and can use semi-transparency colors. All without any color loss.

For more see IM examples, Common File formats ... 6/formats/
Anthony Thyssen -- Webmaster for ImageMagick Example Pages