Hi John,
The simplest way would be to do:
color_map = new ScalarMap(v, Display.RGB);
display.add(color_map);
at display configuration time.
Then in the method where your shape changes, compute the minimum and maximum
radius values, store them in variables min and max, and do:
color_map.setRange(min, max);
If you always want a given radius to be a given color, then instead pick a
constant min and max and apply the setRange once during display configuration
time.
-Curtis
At 03:25 PM 1/17/2002, you wrote:
>Hello,
>
>I have mapped colors on to the surface of my shape with
>
>display.addMap(new ScalarMap(v, Display.RGB));
>
>The mapping values are based on the radius from the origin to the surface of
>the shape. The shape may start as a sphere giving a single color (green).
>The problem comes when my shape mutates its form (say from the sphere to an
>ellipsoid). Apparently, the "sensitivity" of Display.RGB was set to be so
>sensitive initially when the shape was a sphere that the new mapping
>immediately covers the entire object with the color blue.
>
>I would like to show the gradual transition of RGB no matter how the shape
>mutates. Does anyone know an method to "reset" the sensitivity of
>Display.RGB?? Thank you!
>
>john