Concept

TriangulationTraits_3

Definition

The concept TriangulationTraits_3 is the first template parameter of the class Triangulation_3. It defines the geometric objects (points, segments, triangles and tetrahedra) forming the triangulation together with a few geometric predicates and constructions on these objects : lexicographical comparison, orientation in case of coplanar points and orientation in space.

Types

TriangulationTraits_3::Point_3
The point type. It must be DefaultConstructible, CopyConstructible and Assignable.

TriangulationTraits_3::Segment_3
The segment type.

TriangulationTraits_3::Tetrahedron_3
The tetrahedron type.

TriangulationTraits_3::Triangle_3
The triangle type.


TriangulationTraits_3::Construct_segment_3
A constructor object that must provide the function operator
Segment_3 operator()(Point_3 p, Point_3 q),
which constructs a segment from two points.

TriangulationTraits_3::Construct_triangle_3
A constructor object that must provide the function operator
Triangle_3 operator()(Point_3 p, Point_3 q, Point_3 r ),
which constructs a triangle from three points.

TriangulationTraits_3::Construct_tetrahedron_3
A constructor object that must provide the function operator
Tetrahedron_3 operator()(Point_3 p, Point_3 q, Point_3 r, Point_3 s),
which constructs a tetrahedron from four points.


TriangulationTraits_3::Compare_xyz_3
A predicate object that must provide the function operator
Comparison_result operator()(Point p, Point q),
which returns EQUAL if the two points are equal. Otherwise it must return a consistent order for any two points chosen in a same line.

TriangulationTraits_3::Coplanar_orientation_3
A predicate object that must provide the function operator
Orientation operator()(Point p, Point q, Point r),
which returns COLLINEAR if the points are collinear. Otherwise it must return a consistent orientation for any three points chosen in a same plane.

TriangulationTraits_3::Orientation_3
A predicate object that must provide the function operator
Orientation operator()(Point p, Point q, Point r, Point s),
which returns POSITIVE, if s lies on the positive side of the oriented plane h defined by p, q, and r, returns NEGATIVE if s lies on the negative side of h, and returns COPLANAR if s lies on h.

Creation

TriangulationTraits_3 traits;
Default constructor.

TriangulationTraits_3 traits ( Triangulation_traits_3 tr);
Copy constructor.

Operations

The following functions give access to the predicate and construction objects:

Construct_tetrahedron_3 traits.construct_tetrahedron_3_object ()
Construct_triangle_3 traits.construct_triangle_3_object ()
Construct_segment_3 traits.construct_segment_3_object ()

Compare_xyz_3 traits.compare_xyz_3_object ()
Coplanar_orientation_3 traits.coplanar_orientation_3_object ()
Orientation_3 traits.orientation_3_object ()

Has Models

CGAL::Exact_predicates_inexact_constructions_kernel (recommended)
CGAL::Exact_predicates_exact_constructions_kernel
CGAL::Filtered_kernel
CGAL::Cartesian
CGAL::Simple_cartesian
CGAL::Homogeneous
CGAL::Simple_homogeneous