Page 1 of 1

-remap makes *almost* everything grayscale?

Posted: 2019-05-05T02:52:01-07:00
by midn
I have ~300 frames I had rendered on Blender, and I wanted to palettize those frames and turn them into a single GIF.

Here's the palette image (it's a crop of a palette image I found on Wikipedia).
Image

Here's my command.

Code: Select all

convert +dither -remap "/home/midnightas/cpp/TMRP/bin/assets/palette.png" -delay 1x24 -verbose f*.png gif.gif
But every color except for one is grayscale. The output may give some hint.

Code: Select all

f0001.png=>gif.gif[0] PNG 640x360 640x360+0+0 8-bit Palette Gray 510=>7c 7583.3518518518521887/0.016130/0.200000db 9.153MB 1851.760u 4:19.149
I've also tried modulating to increase the saturation, thinking that maybe the color distance function is getting it "wrong", but it did not fix the issue.

Re: -remap makes *almost* everything grayscale?

Posted: 2019-05-05T04:23:50-07:00
by snibgo
But what is the problem? Your map has pixels that mostly have very high saturation. If your input is an ordinary photo, most pixels will be low saturation, so those pixels will be closer to a gray than a high saturation.

If you want a non-gray output, try removing "+dither". Then the errors in mapping each pixel will accumulate, so more pixels are likely to need mapping to a high-saturation colour.

Or you could decrease the saturation of the map image, or increase the saturation of each input *.png.

Also: your map has 399 unique colours. A GIF can record only 256 colours, so IM will do further colour reduction after the map. I suggest using a map with only 256 colours.

Also: your IM command should be in the logical order: read the inputs, then "-remap", then write the outputs.