% +------------------------------------------------------------------------+ % | Reference manual page: ConstrainedTriangulationTraits_2.tex % +------------------------------------------------------------------------+ % | 05.02.2002 Mariette Yvinec % | Package: Triangulation_2 % | \RCSdef{\RCSConstrainedTriangulationTraitsRev}{$Id$} \RCSdefDate{\RCSConstrainedTriangulationTraitsDate}{$Date$} % | %%RefPage: end of header, begin of main body % +------------------------------------------------------------------------+ \begin{ccRefConcept}{ConstrainedTriangulationTraits_2} %% \ccHtmlCrossLink{} %% add further rules for cross referencing links %% \ccHtmlIndexC[concept]{} %% add further index entries \ccDefinition The concept \ccRefName\ defines the requirements for the geometric traits class of a constrained triangulation ( \ccc{Constrained_Triangulation_2}) that supports intersections of input constraints (i. e. when the template parameter \ccc{Itag} is instantiated by one of the tag classes \ccc{Exact_intersections_tag} or \ccc{Exact_predicates_tag}). This concept refines the concept \ccc{TriangulationTraits_2}, adding requirements for function objects to compute the intersection points of two constraints. When \ccc{Exact_predicates_tag} is used, the traits class is also required to provide additional types to compute the squared distance between a point and a line \ccRefines \ccc{TriangulationTraits_2} \ccTypes \ccNestedType{Intersect_2}{A function object whose operator() computes the intersection of two segments : \\ \ccc{Object_2 operator()(Segment_2 s1, Segment_2 s2);} Returns the intersection of \ccc{s1} and \ccc{s2}.} When the constrained triangulation is instantiated with the intersection tag \ccc{Exact_predicates_tag}, the used algorithm needs to be able to compare some distances between points and lines and the following types are further required. \ccNestedType{RT}{A number type supporting the comparison operator \ccc{<}.} \ccNestedType{Line_2}{The line type.} \ccGlue \ccNestedType{Construct_line_2} {A function object whose operator() constructs a line from two points : \\ \ccc{Line_2 operator()(Point_2 p1, Point_2 p2)}.} \ccGlue \ccNestedType{Compute_squared_distance_2}{A function object with an operator() designed to compute the squared distance between a line and a point : \ccc{RT operator()(Point_2 p1, Line_2);} Return the squared distance between \ccc{p} and \ccc{l}.} \ccCreationVariable{traits} %% choose variable name \ccHeading{Access to constructor object} \ccMethod{Intersect_2 intersect_2_object();}{} \ccMethod{Construct_line_2 construct_line_2_object();}{required when the intersection tag is \ccc{Exact_predicates_tag}.} \ccMethod{Compute_squared_distance_2 compute_squared_distance_2_object();} {required when the intersection tag is \ccc{Exact_predicates_tag}.} \ccHasModels The kernels of \cgal\ are models for this traits class. \ccSeeAlso \ccc{TriangulationTraits_2} \\ \ccc{ConstrainedDelaunayTriangulationTraits_2} \\ \ccc{CGAL:Constrained_Triangulation_2} %\ccExample %A short example program. %Instead of a short program fragment, a full running program can be %included using the %\verb|\ccIncludeExampleCode{Package/ConstrainedTriangulationPlusTraits_2_prog.cpp}| %macro. The program example would be part of the source code distribution and %also part of the automatic test suite. %\begin{ccExampleCode} %void your_example_code() { %} %\end{ccExampleCode} %% \ccIncludeExampleCode{Package/ConstrainedTriangulationPlusTraits_2_prog.cpp} \end{ccRefConcept} % +------------------------------------------------------------------------+ %%RefPage: end of main body, begin of footer % EOF % +------------------------------------------------------------------------+