Class ContourPlot.TriangleDetails

  • All Implemented Interfaces:
    java.lang.Cloneable
    Enclosing class:
    ContourPlot

    public class ContourPlot.TriangleDetails
    extends java.lang.Object
    implements java.lang.Cloneable
    Specification of a triangle which comprises vertex locations, colors and picking color.
    Author:
    hageldave
    • Field Detail

      • p0

        public java.awt.geom.Point2D p0
      • p1

        public java.awt.geom.Point2D p1
      • p2

        public java.awt.geom.Point2D p2
      • c0

        public java.util.function.IntSupplier c0
      • c1

        public java.util.function.IntSupplier c1
      • c2

        public java.util.function.IntSupplier c2
      • pickColor

        public int pickColor
    • Constructor Detail

      • TriangleDetails

        public TriangleDetails​(java.awt.geom.Point2D p0,
                               java.awt.geom.Point2D p1,
                               java.awt.geom.Point2D p2)
      • TriangleDetails

        public TriangleDetails​(double x0,
                               double y0,
                               double x1,
                               double y1,
                               double x2,
                               double y2)
    • Method Detail

      • setPickColor

        public ContourPlot.TriangleDetails setPickColor​(int pickID)
        Sets the picking color. When a non 0 transparent color is specified its alpha channel will be set to 0xff to make it opaque.
        Parameters:
        pickID - picking color of the triangle (see ContourPlot.Triangles for details)
        Returns:
        this for chaining
      • setColor0

        public ContourPlot.TriangleDetails setColor0​(java.util.function.IntSupplier color)
        Sets the color for vertex 0
        Parameters:
        color - integer packed ARGB color value (e.g. 0xff00ff00 = opaque green)
        Returns:
        this for chaining
      • setColor1

        public ContourPlot.TriangleDetails setColor1​(java.util.function.IntSupplier color)
        Sets the color for vertex 1
        Parameters:
        color - integer packed ARGB color value (e.g. 0xff00ff00 = opaque green)
        Returns:
        this for chaining
      • setColor2

        public ContourPlot.TriangleDetails setColor2​(java.util.function.IntSupplier color)
        Sets the color for vertex 2
        Parameters:
        color - integer packed ARGB color value (e.g. 0xff00ff00 = opaque green)
        Returns:
        this for chaining
      • setColor

        public ContourPlot.TriangleDetails setColor​(java.util.function.IntSupplier color)
        Sets the color of the triangle (all vertices)
        Parameters:
        color - integer packed ARGB color value (e.g. 0xff00ff00 = opaque green)
        Returns:
        this for chaining
      • setColor0

        public ContourPlot.TriangleDetails setColor0​(int color)
        Sets the color of vertex 0
        Parameters:
        color - integer packed ARGB color value (e.g. 0xff00ff00 = opaque green)
        Returns:
        this for chaining
      • setColor1

        public ContourPlot.TriangleDetails setColor1​(int color)
        Sets the color of vertex 1
        Parameters:
        color - integer packed ARGB color value (e.g. 0xff00ff00 = opaque green)
        Returns:
        this for chaining
      • setColor2

        public ContourPlot.TriangleDetails setColor2​(int color)
        Sets the color of vertex 2
        Parameters:
        color - integer packed ARGB color value (e.g. 0xff00ff00 = opaque green)
        Returns:
        this for chaining
      • setColor

        public ContourPlot.TriangleDetails setColor​(int color)
        Sets the color of the triangle (all vertices)
        Parameters:
        color - integer packed ARGB color value (e.g. 0xff00ff00 = opaque green)
        Returns:
        this for chaining
      • setColor0

        public ContourPlot.TriangleDetails setColor0​(java.awt.Color color)
        Sets the color of vertex 0
        Parameters:
        color - of v0
        Returns:
        this for chaining
      • setColor1

        public ContourPlot.TriangleDetails setColor1​(java.awt.Color color)
        Sets the color of vertex 1
        Parameters:
        color - of v1
        Returns:
        this for chaining
      • setColor2

        public ContourPlot.TriangleDetails setColor2​(java.awt.Color color)
        Sets the color of vertex 2
        Parameters:
        color - of v2
        Returns:
        this for chaining
      • setColor

        public ContourPlot.TriangleDetails setColor​(java.awt.Color color)
        Sets the color the triangle (all vertices)
        Parameters:
        color - of the triangle
        Returns:
        this for chaining