> . . .
> Nah, that wasn't the hard stuff. Hard is to find why the attached code
> is not working...
> I'm attaching a test program and a color table. The program creates some
> 2D data, displays with rgb and then pops up a file chooser for the
> user to load a color table. As said, the table comes free with this
> email and looks like this:
> r g b
> 1 1 1
> 1 0 0
> 0 1 0
> 0 0 1
> 0 0 1
> 1 0 1
> 1 1 0
> 0 0 0
> It's a white, r,g,b,c,m,y, black table. The problem is that the color
> control (or whatever!) ignores all colors but the initial white (1,1,1)
> and red (1,0,0).
> Note: colors must be between 0.0 and 1.0 (as specified in the
> Can anyone tell me what's wrong or what I'm doing wrong?
The problem is that a Function passed to
ColorControl.setFunction() must have a domain
Set with extents in (0.0, 1.0). The call to
visad.jmet.DumpType.dumpDataType() gives the
domain Set as:
Linear1DSet (index) Range = 0.0 to 7.0 step 1.0
Which must be what the TextAdapter creates. It
would need to be:
Linear1DSet (index) Range = 0.0 to 1.0 step 0.14285