On Apr 4, 2009, at 7:16 PM, Sean Luke wrote:
> On Apr 3, 2009, at 7:19 PM, Mark Coletti wrote:
>
>> landPortrayal.setMap(
>> new sim.util.gui.SimpleColorMap(
>> new Color[] {Color.GREEN, Color.YELLOW}));
>
> You mapped the integer value 0 to green and the integer value 1 to
> yellow. What you want is a continuous map. Try:
>
> landPortrayal.setMap(
> new sim.util.gui.SimpleColorMap(0.0, 1.0, Color.GREEN,
> Color.YELLOW));
>
> I've noticed that SimpleColorMap's constructors aren't documented.
> That needs to be fixed.
I did a commit on SimpleColorMap with improved documentation. I
include the code here for your enlightenment.
Sean
|