![]() |
UtilsLite
Utilities for C++ programming
|
A class representing a 2D triangle defined by three vertices. More...
#include <Utils_GG2D.hh>
Public Member Functions | |
Triangle2D () | |
Default constructor for the triangle. | |
A class representing a 2D triangle defined by three vertices.
The Triangle2D
class defines a 2D triangle using three points, \( P_a \), \( P_b \), and \( P_c \), which represent the vertices of the triangle. This class provides a structure to represent and manipulate a triangle in a two-dimensional space, allowing for operations such as area calculation, centroid determination, and intersection checks with other geometric entities.
Real | The data type used for the coordinates of the triangle's vertices, typically a floating-point type (e.g., float, double). |
|
inline |
Default constructor for the triangle.
Initializes a new triangle with uninitialized vertices. This constructor can be used to create an empty triangle which can later be defined using specific points.