uk.ac.starlink.ttools.plot
Interface DataColorTweaker

All Superinterfaces:
ColorTweaker
All Known Implementing Classes:
ShaderTweaker

public interface DataColorTweaker
extends ColorTweaker

ColorTweaker which can adjust plotting colours on the basis of a supplied array of values (auxiliary data coordinates).

Since:
5 Jun 2007
Author:
Mark Taylor

Method Summary
 int getNcoord()
          Returns the size of coordinate array which should be submitted to setCoords(double[]).
 boolean setCoords(double[] coords)
          Configures this object with a coordinate array which determines what colour adjustments subsequent calls to ColorTweaker.tweakColor(java.awt.Color) will perform.
 
Methods inherited from interface uk.ac.starlink.ttools.plot.ColorTweaker
tweakColor, tweakColor
 

Method Detail

setCoords

boolean setCoords(double[] coords)
Configures this object with a coordinate array which determines what colour adjustments subsequent calls to ColorTweaker.tweakColor(java.awt.Color) will perform.

The return value indicates whether the supplied coordinates are within the visible data ranges; iff they are outside this range false will be returned. Null auxiliary coordinates do not cause a false return, and neither do they cause any change to the input colour. In case of a false return this object is left in an undefined state, so tweakColor should only be called following a successful (true) call of this method.

Parameters:
coords - full coordinate array
Returns:
true iff this object has been set to a usable state

getNcoord

int getNcoord()
Returns the size of coordinate array which should be submitted to setCoords(double[]).

Returns:
coordinate size array


Copyright © 2009 Central Laboratory of the Research Councils. All Rights Reserved.