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
  • Constructor Details

    • DensityPlotState

      public DensityPlotState()
  • Method Details

    • 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
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class PlotState
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class PlotState