Class Pixel

  • All Implemented Interfaces:
    Destroyable, GlobalInfoSupporter, LoggingLevelHandler, LoggingSupporter, OptionHandler, QuickInfoSupporter, SizeOfHandler, Serializable

    public class Pixel
    extends AbstractColorDrawOperation
    Draws a pixel with the specified color at the specified location.

    Valid options are:

    -D <int> (property: debugLevel)
        The greater the number the more additional info the scheme may output to 
        the console (0 = off).
        default: 0
        minimum: 0
     
    -color <java.awt.Color> (property: color)
        The color of the pixel.
        default: #000000
     
    -x <int> (property: X)
        The X position of the pixel (1-based).
        default: 1
        minimum: 1
     
    -y <int> (property: Y)
        The Y position of the pixel (1-based).
        default: 1
        minimum: 1
     
    -type <RGBA|COLOR> (property: type)
        The type of value to use for the pixel.
        default: RGBA
     
    -rgba <int> (property: RGBA)
        The RGBA value (>= 0).
        default: 0
        minimum: 0
     
    Author:
    fracpete (fracpete at waikato dot ac dot nz)
    See Also:
    Serialized Form
    • Field Detail

      • m_X

        protected int m_X
        the X position of the pixel (1-based).
      • m_Y

        protected int m_Y
        the Y position of the pixel (1-based).
      • m_RGBA

        protected int m_RGBA
        the RGBA value of the pixel.
    • Constructor Detail

      • Pixel

        public Pixel()
    • Method Detail

      • setX

        public void setX​(int value)
        Sets the X position of the pixel.
        Parameters:
        value - the position, 1-based
      • getX

        public int getX()
        Returns the X position of the pixel.
        Returns:
        the position, 1-based
      • XTipText

        public String XTipText()
        Returns the tip text for this property.
        Returns:
        tip text for this property suitable for displaying in the GUI or for listing the options.
      • setY

        public void setY​(int value)
        Sets the Y position of the pixel.
        Parameters:
        value - the position, 1-based
      • getY

        public int getY()
        Returns the Y position of the pixel.
        Returns:
        the position, 1-based
      • YTipText

        public String YTipText()
        Returns the tip text for this property.
        Returns:
        tip text for this property suitable for displaying in the GUI or for listing the options.
      • setType

        public void setType​(Pixel.PixelValueType value)
        Sets the type of value to use.
        Parameters:
        value - the type
      • getType

        public Pixel.PixelValueType getType()
        Returns the type of value to use.
        Returns:
        the type
      • typeTipText

        public String typeTipText()
        Returns the tip text for this property.
        Returns:
        tip text for this property suitable for displaying in the GUI or for listing the options.
      • setRGBA

        public void setRGBA​(int value)
        Sets the RGBA value of the pixel.
        Parameters:
        value - the RGBA value
      • getRGBA

        public int getRGBA()
        Returns the RGBA value of the pixel.
        Returns:
        the RGBA value
      • RGBATipText

        public String RGBATipText()
        Returns the tip text for this property.
        Returns:
        tip text for this property suitable for displaying in the GUI or for listing the options.