Package gov.nih.mipav.model.algorithms
Class ContourPlot.TriangleDetails
- java.lang.Object
-
- gov.nih.mipav.model.algorithms.ContourPlot.TriangleDetails
-
- All Implemented Interfaces:
java.lang.Cloneable
- Enclosing class:
- ContourPlot
public class ContourPlot.TriangleDetails extends java.lang.Object implements java.lang.CloneableSpecification of a triangle which comprises vertex locations, colors and picking color.- Author:
- hageldave
-
-
Constructor Summary
Constructors Constructor Description TriangleDetails(double x0, double y0, double x1, double y1, double x2, double y2)TriangleDetails(java.awt.geom.Point2D p0, java.awt.geom.Point2D p1, java.awt.geom.Point2D p2)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ContourPlot.TriangleDetailsclone()ContourPlot.TriangleDetailscopy()Returns a shallow copy of this triangle.ContourPlot.TriangleDetailssetColor(int color)Sets the color of the triangle (all vertices)ContourPlot.TriangleDetailssetColor(java.awt.Color color)Sets the color the triangle (all vertices)ContourPlot.TriangleDetailssetColor(java.util.function.IntSupplier color)Sets the color of the triangle (all vertices)ContourPlot.TriangleDetailssetColor0(int color)Sets the color of vertex 0ContourPlot.TriangleDetailssetColor0(java.awt.Color color)Sets the color of vertex 0ContourPlot.TriangleDetailssetColor0(java.util.function.IntSupplier color)Sets the color for vertex 0ContourPlot.TriangleDetailssetColor1(int color)Sets the color of vertex 1ContourPlot.TriangleDetailssetColor1(java.awt.Color color)Sets the color of vertex 1ContourPlot.TriangleDetailssetColor1(java.util.function.IntSupplier color)Sets the color for vertex 1ContourPlot.TriangleDetailssetColor2(int color)Sets the color of vertex 2ContourPlot.TriangleDetailssetColor2(java.awt.Color color)Sets the color of vertex 2ContourPlot.TriangleDetailssetColor2(java.util.function.IntSupplier color)Sets the color for vertex 2ContourPlot.TriangleDetailssetPickColor(int pickID)Sets the picking color.
-
-
-
Method Detail
-
copy
public ContourPlot.TriangleDetails copy()
Returns a shallow copy of this triangle.- Returns:
- copy of this triangle
-
clone
public ContourPlot.TriangleDetails clone()
- Overrides:
clonein classjava.lang.Object
-
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 (seeContourPlot.Trianglesfor 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
-
-