CGAL 6.3 - 1D Arrangements
Loading...
Searching...
No Matches
CGAL::Arrangement_on_curve_1 Namespace Reference

Classes

class  Arrangement_on_curve_1
class  Ft_traits_1
 Ft_traits_1 is a minimal, scalar model of the AocTraits_1 concept. More...
class  Geom_traits_2_adaptor_1
 adapts any 2D geometry traits class of the 2D Arrangements package (i.e., any model of the ArrangementTraits_2 concept, or a refinement thereof) into a 1D geometry traits class, suitable for use with Arrangement_on_curve_1. More...
class  Line_2_traits_1
 Line_2_traits_1 is a geometric traits model of AocTraits_1 designed for subdivisions along an infinite supporting line embedded in 2D Euclidean space. More...
class  Line_3_traits_1
 Line_3_traits_1 is a geometric traits model of AocTraits_1 designed for subdivisions along an infinite supporting line embedded in 3D Euclidean space. More...
class  Line_d_traits_1
 Line_d_traits_1 is a geometric traits model of AocTraits_1 designed for subdivisions along an infinite supporting line embedded in a d-dimensional coordinate space. More...
class  Unbounded_topology_traits
 The class template Unbounded_topology_traits provides a model of the AocTopologyTraits concept for 1D arrangements embedded on an unbounded carrier curve. More...

Functions

template<typename GeometryTraits, typename TopologyTraits>
Arrangement_on_curve_1< GeometryTraits, TopologyTraits >::Vertex_descriptor insert (Arrangement_on_curve_1< GeometryTraits, TopologyTraits > &arr, const typename GeometryTraits::Point_1 &p)
 inserts a point into an arrangement.
template<typename GeometryTraits_1, typename TopologyTraits>
std::ostream & operator<< (std::ostream &os, const Arrangement_on_curve_1< GeometryTraits_1, TopologyTraits > &arr)
 Inserts the arrangement object arr into the output stream os.
template<typename GeometryTraits_1, typename TopologyTraits>
std::istream & operator>> (std::istream &is, Arrangement_on_curve_1< GeometryTraits_1, TopologyTraits > &arr)
 Extracts an arrangement from a given input stream is.
template<typename GeometryTraits, typename TopologyTraits>
Arrangement_on_curve_1< GeometryTraits, TopologyTraits >::Const_location_result locate (Arrangement_on_curve_1< GeometryTraits, TopologyTraits > &arr, const typename GeometryTraits::Point_1 &q)
 locates a query point in a given arrangement.
template<typename GeometryTraits, typename TopologyTraits>
Arrangement_on_curve_1< GeometryTraits, TopologyTraits >::Location_result locate (Arrangement_on_curve_1< GeometryTraits, TopologyTraits > &arr, const typename GeometryTraits::Point_1 &q)
 locates a query point in a given arrangement.
template<typename GeometryTraitsA, typename GeometryTraitsB, typename GeometryTraitsRes, typename TopologyTraitsA, typename TopologyTraitsB, typename TopologyTraitsRes, typename OverlayVisitor>
void overlay (const Arrangement_on_curve_1< GeometryTraitsA, TopologyTraitsA > &arr_a, const Arrangement_on_curve_1< GeometryTraitsB, TopologyTraitsB > &arr_b, Arrangement_on_curve_1< GeometryTraitsRes, TopologyTraitsRes > &arr_r, OverlayVisitor &visitor)
 computes the overlay of two input 1D arrangement objects arr_a and arr_b, and sets the output arrangement arr_r to represent the overlaid arrangement.
template<typename GeometryTraitsA, typename GeometryTraitsB, typename GeometryTraitsRes, typename TopologyTraitsA, typename TopologyTraitsB, typename TopologyTraitsRes>
void overlay (const Arrangement_on_curve_1< GeometryTraitsA, TopologyTraitsA > &arr_a, const Arrangement_on_curve_1< GeometryTraitsB, TopologyTraitsB > &arr_b, Arrangement_on_curve_1< GeometryTraitsRes, TopologyTraitsRes > &arr_r)
 computes the overlay of two input 1D arrangement objects arr_a and arr_b, and sets the output arrangement arr_r to represent the overlaid arrangement.

Function Documentation

◆ locate()

template<typename GeometryTraits, typename TopologyTraits>
Arrangement_on_curve_1< GeometryTraits, TopologyTraits >::Location_result CGAL::Arrangement_on_curve_1::locate ( Arrangement_on_curve_1< GeometryTraits, TopologyTraits > & arr,
const typename GeometryTraits::Point_1 & q )

locates a query point in a given arrangement.

Parameters
arrthe arrangement
qthe query point
Returns
a discriminated union container of type Location_result (an instance of std::variant template) that identifies a cell (i.e., a vertex or an edge). In particular, the returned object is a Vertex_descriptor if the geometric embedding of the identified vertex coincides exactly with the query point q, or otherwise an Edge_desriptor, such that the geometric embedding of the identified edge contains q in its interior. The search is implemented via a linear topological walk from left to right starting at unbounded_left_edge(), using the geometry traits functor to locate the precise cell containing the query point parameter.