Page 1 of 1

Create colormap from multiple images

Posted: 2014-05-02T03:55:37-07:00
by danc81
Hi,

I have a series of large images (14000x14000+) which I need to resize and convert to 256 colours, however when converting these using -resize <width>x<height> -dither None -colors 256 I find that the colours don't quite match at the tile borders. I would like to generate a colormap across all the images to ensure they match but the images are too large to fit into memory when combined.

Is there a way to do this with ImageMagick?

Thanks in advance.

Re: Create colormap from multiple images

Posted: 2014-05-02T04:18:41-07:00
by snibgo
You could resize one and reduce to 256 colours. Then each other image could be resized and remapped to the unique colours in the first image.

EDIT: Another strategy would be to resize each large image to be small enough that you can append them all together. Reduce this to 256 colours, and find the unique colours. This can be used for a remap. Then you resize each large image to the dimensions you want, and remap it.

Re: Create colormap from multiple images

Posted: 2014-05-04T05:40:52-07:00
by Werty
snibgo wrote:Another strategy would be to resize each large image to be small enough that you can append them all together. Reduce this to 256 colours, and find the unique colours. This can be used for a remap. Then you resize each large image to the dimensions you want, and remap it.
Perhaps finding the average of all colors would be better for a more spread coverage, using "-evaluate-sequence mean", no appending needed either.