public class ColorContourCanvas extends java.awt.Canvas
This component creates a color contour plot for a rectangular array of double values. The canvas is partitioned into an array of square cells and the contour plot is created by painting each cell with a color corresponding to a the data value at the center of the cell. The data values are obtained by interpolating the input data using bi-linear interpolation.
Chris Anderson, 6/24/98, (C) UCLA 1998.
·
ColorContourCanvas()Constructs a new ColorContourCanvas.
·
public void setData(double [][] inputData)Sets the data to be contoured.
·
public void setData(double [] inputData, int xCount, int yCount)Sets the data to be contoured.
·
public void setDataRange().Sets the maximum and minimum data values to be contoured based on contoured data.
·
public void setDataRange(double dMin, double dMax)Sets the maximum and minimum data values to be contoured.
·
public void setResolution(int PanelCount)Sets the resolution (array size) used to create the color contour.
·
public int getResolution()Returns the resolution used for the color contour.
·
public void setupColors()Internally sets up a default color table to be used for the color contour.
·
public void setupColorTable(double [] r, double [] g, double [] b)Sets up color table with values from the r,g and b arrays.
·
public void setColorCount(int cCount)Sets the number of colors to be used in the contour.
·
public void setColorTableEntry(int index, double r, double g, double b)Sets a specific color table entry.
·
public int getColorCount()Returns the number of colors used in the color table.
·
public void setData(double [][] inputData)Sets the data to be contoured. The size of the data is determined from the array itself.
·
public void setData(double [] inputData, int xCount, int yCount)Sets the data to be contoured. The data for a two dimensional array of size xCount by yCount is passed in the linear array inputData. It is assumed that this data is stored by ROWS (Fortran convention)
·
public void setDataRange().The data range used for contour plotting is determined from the maximum and minimum of the input data values.
·
public void setDataRange(double dMin, double dMax)The data range used for contour plotting is set to [dMin, dMax].
·
public void setResolution(int PanelCount)Sets the resolution (array size) used to create the color contour. The array used to create the color contour is of size PanelCount by PanelCount. The array size need not be the same size as the data array.
·
public int getResolution()Returns the resolution used for the color contour.
·
public void setupColors()Internally sets up a default color table to be used for the color contour.
·
public void setupColorTable(double [] r, double [] g, double [] b) Sets up color table with values from the r,g and b arrays. The number of colors is obtained from the sizes of the r, g and b arrays.
·
public void setColorCount(int cCount)Sets the number of colors to be used in the contour.
·
public void setColorTableEntry(int index, double r, double g, double b)Sets a specific color table entry.
·
public int getColorCount() Returns the number of colors used in the color table.