Hi, all,

Happy Eastertide.

I deal a lot with heightmaps, which you can take to be grayscale images for which pixel values change "smoothly" in any direction.

It would be helpful sometimes if I could "see" adjacent contours of individual pixel values "next" to each other. I think what this means is that I'm looking for a way to map values which are adjacent in the original to values, gray or color, which are "far enough apart to be easily detectible" in a new pseudo-colored image.

I wonder if it might work to work with the 2 half palettes of continuous shading or color, 0-127 and 128-256, and subdivide each into 4 parts, for a total of 8 subpalettes. A pixel with value PV in the range 0-127 will be assigned a new value from an offset into a subpalette in the other half-palette, which subpalette being determined by a mathematical expression like PV mod 4, and with an offset being the same as the PVs own offset into its original subpalette.

For example, for two contours lying next to each other at PV=100, and PV=101.

100 mod 4 = 0 => 1st subpalette in top half-palette, 128-159, and PV=100 is in the 4th subpalette in the bottom half-palette, 96-127, with an offset of 5

101 mod 4 = 1 => 2nd subpalette in top, 160-191, and PV=101, is in 4th subpalette too, with an offset of 6

So PV=100 would map to PV=128+5=133

while PV=101 would map to PV=160+6=166, 33 rgb away.

Alternatively, I'm looking for an optimally noisy/chaotic/high-entropy pseudocolor gradient in which colors adjacent to each other in the original map to colors on opposite sides of the color wheel.

I selected the tropical colors map for an initial experiment with Colors->Map->GradientMap, which does give a hint for what a result might look like, but still results in grayscale values near each other mapping to shades near each other.

Attachment:

BW.png [ 61.51 KiB | Viewed 467 times ]
Attachment:

PC.png [ 121.84 KiB | Viewed 467 times ]
I had a brief notion that simply mapping levels to either 0 or 255, based on being even or odd, would be interesting, but I want to the mapping to be reversible.

I also just had an inspiration that G'MIC's computation engine might be a good place to experiment.

(Interesting: "What would you expect to happen if you continued to apply Colors->Map->GradientMap to the pseudocolor result?" For the example above, the output tends to monochromatic. "Is there a palette which will guarantee this convergence will not happen?")