Struct Triangle2DF
A 2D triangle
public struct Triangle2DF : IConvexPolygonF, IEquatable<Triangle2DF>
- Implements
- Inherited Members
Constructors
Triangle2DF(PointF, PointF, PointF)
Create a triangle using the specific vertices
public Triangle2DF(PointF v0, PointF v1, PointF v2)
Parameters
Properties
Area
Get the area of this triangle
public double Area { get; }
Property Value
Centeroid
Returns the centroid of this triangle
public PointF Centeroid { get; }
Property Value
V0
One of the vertex of the triangle
public PointF V0 { get; set; }
Property Value
V1
One of the vertex of the triangle
public PointF V1 { get; set; }
Property Value
V2
One of the vertex of the triangle
public PointF V2 { get; set; }
Property Value
Methods
Equals(Triangle2DF)
Compare two triangles and return true if equal
public bool Equals(Triangle2DF tri)
Parameters
tri
Triangle2DFthe other triangles to compare with
Returns
- bool
true if the two triangles equals, false otherwise
GetVertices()
Get the vertices of this triangle
public PointF[] GetVertices()
Returns
- PointF[]
The vertices of this triangle