Package uk.ac.starlink.ttools.plot
Class DensityPlotState
- java.lang.Object
-
- uk.ac.starlink.ttools.plot.PlotState
-
- uk.ac.starlink.ttools.plot.DensityPlotState
-
public class DensityPlotState extends PlotState
PlotState specialist subclass used for density maps.- Since:
- 1 Dec 2005
- Author:
- Mark Taylor
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class uk.ac.starlink.ttools.plot.PlotState
PlotState.SimpleValueInfo
-
-
Constructor Summary
Constructors Constructor Description DensityPlotState()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(java.lang.Object o)doublegetHiCut()Gets the upper cut value, as a fraction of the visible bins.ShadergetIndexedShader()Returns the shader to be used for shading pixels in indexed (non-RGB) mode.doublegetLoCut()Gets the lower cut value, as a fraction of the visible bins.booleangetLogZ()Determines whether the colour intensity is to be plotted on a log or linear scale.intgetPixelSize()Gets the size of each data pixel (bin) in screen pixels.booleangetRgb()Determines whether the plot will be coloured.booleangetWeighted()Determines whether non-unit weighting is (maybe) in force for this state.inthashCode()voidsetHiCut(double frac)Sets the upper cut value, as a fraction of the visible bins.voidsetIndexedShader(Shader indexedShader)Sets the shader object to be used for shading pixels in indexed (non-RGB) mode.voidsetLoCut(double frac)Sets the lower cut value, as a fraction of the visible bins.voidsetLogZ(boolean zLog)Sets whether the colour intensity is to be plotted on a log or linear scale.voidsetPixelSize(int psize)Sets the size of each data pixel (bin) in screen pixels.voidsetRgb(boolean rgb)Sets whether the plot will be coloured.voidsetWeighted(boolean weighted)Sets whether non-unit weighting is (maybe) in force for this state.-
Methods inherited from class uk.ac.starlink.ttools.plot.PlotState
compare, getAntialias, getAxes, getAxisLabels, getConverters, getFlipFlags, getGrid, getLogFlags, getMainNdim, getPlotData, getRanges, getShaders, getValid, setAntialias, setAxes, setAxisLabels, setConverters, setFlipFlags, setGrid, setLogFlags, setMainNdim, setPlotData, setRanges, setShaders, setValid
-
-
-
-
Method Detail
-
setRgb
public void setRgb(boolean rgb)
Sets whether the plot will be coloured.- Parameters:
rgb- true for colour, false for monochrome
-
getRgb
public boolean getRgb()
Determines whether the plot will be coloured.- Returns:
- true for colour, false for monochrome
-
setLogZ
public void setLogZ(boolean zLog)
Sets whether the colour intensity is to be plotted on a log or linear scale.- Parameters:
zLog- true iff you want logarithmic scaling of intensity
-
getLogZ
public boolean getLogZ()
Determines whether the colour intensity is to be plotted on a log or linear scale.- Returns:
- true iff scaling will be logarithmic
-
setPixelSize
public void setPixelSize(int psize)
Sets the size of each data pixel (bin) in screen pixels.- Parameters:
psize- pixel size
-
getPixelSize
public int getPixelSize()
Gets the size of each data pixel (bin) in screen pixels.- Returns:
- pixel size
-
setLoCut
public void setLoCut(double frac)
Sets the lower cut value, as a fraction of the visible bins. This determines the brightness of the plot.- Parameters:
frac- lower cut value (0-1)
-
getLoCut
public double getLoCut()
Gets the lower cut value, as a fraction of the visible bins. This determines the brightness of the plot.- Returns:
- lower cut value (0-1)
-
setHiCut
public void setHiCut(double frac)
Sets the upper cut value, as a fraction of the visible bins. This determines the brightness of the plot.- Parameters:
frac- upper cut value (0-1)
-
getHiCut
public double getHiCut()
Gets the upper cut value, as a fraction of the visible bins. This determines the brightness of the plot.- Returns:
- upper cut value (0-1)
-
setWeighted
public void setWeighted(boolean weighted)
Sets whether non-unit weighting is (maybe) in force for this state.- Parameters:
weighted- whether weights are used
-
getWeighted
public boolean getWeighted()
Determines whether non-unit weighting is (maybe) in force for this state.- Returns:
- whether weights are used
-
setIndexedShader
public void setIndexedShader(Shader indexedShader)
Sets the shader object to be used for shading pixels in indexed (non-RGB) mode.- Parameters:
indexedShader- shader
-
getIndexedShader
public Shader getIndexedShader()
Returns the shader to be used for shading pixels in indexed (non-RGB) mode.- Returns:
- shader
-
-