Frage

I'd like to make a script where I could put an image file(in indexed mode) as input then the return will be one image (in rgb mode).

It is like something gimp does in the interactive mode when you you click on Image -> Mode then click on rgb (http://docs.gimp.org/en/images/tutorials/quickie-mode-menu.png), I want to do the same thing but in the linux terminal (or in python) with a lot of images every day.

Any tips?

Thanks in Advance, sorry for the bad english.

War es hilfreich?

Lösung

This would be done easier/faster with ImageMagick.

Then you would be able to run the following command from your shell:

$ convert cmyk_image.jpg -colorspace rgb rgb_image.jpg

A guide/reference is available at the ImageMagick project wiki.

Andere Tipps

I tried :

$ convert indexed_image.tif -colorspace rgb rgb_image.tif

This is TIFF with an indexed table RGB, but the result colors are slightly different (darker and more intense). E.g. table entry 58 which is 192 248 200 (light green) transforms into 134 239 147 (darker green).

Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top