CGAL 4.6.2 - 2D Arrangements
|
#include <CGAL/Arr_linear_traits_2.h>
The Curve_2
(and the X_monotone_curve_2
) class nested within the linear-traits can represent all types of linear objects.
The class supports the copy and default constructor and the assignment operator. In addition, the operator<<
and operator>>
for linear objects are defined for standard output and input streams.
Types | |
typedef Kernel::Point_2 | Point_2 |
typedef Kernel::Segment_2 | Segment_2 |
typedef Kernel::Ray_2 | Ray_2 |
typedef Kernel::Line_2 | Line_2 |
Creation | |
Curve_2 (const Segment_2 &seg) | |
constructs an line segment. | |
Curve_2 (const Ray_2 &ray) | |
constructs a ray. | |
Curve_2 (const Line_2 &ln) | |
constructs a line. | |
Access Functions | |
bool | is_segment () const |
returns whether c is a segment (has two bounded endpoints). | |
Segment_2 | segment () const |
returns a segment object equivalent to c . More... | |
bool | is_ray () const |
returns whether c is a ray (has a bounded source point and its other end is unbounded). | |
Ray_2 | ray () const |
returns a ray object equivalent to c . More... | |
bool | is_line () const |
returns whether c is a line (has only unbounded ends). | |
Line_2 | line () const |
returns a line object equivalent to c . More... | |
Line_2 | supporting_line () const |
returns the supporting line of c . More... | |
Point_2 | source () const |
returns c 's source point. More... | |
Point_2 | target () const |
returns c 's target point. More... | |
Line_2 CGAL::Arr_linear_traits_2< Kernel >::Curve_2::line | ( | ) | const |
returns a line object equivalent to c
.
c
is a line. Ray_2 CGAL::Arr_linear_traits_2< Kernel >::Curve_2::ray | ( | ) | const |
returns a ray object equivalent to c
.
c
is a ray. Segment_2 CGAL::Arr_linear_traits_2< Kernel >::Curve_2::segment | ( | ) | const |
returns a segment object equivalent to c
.
c
is a segment. Point_2 CGAL::Arr_linear_traits_2< Kernel >::Curve_2::source | ( | ) | const |
returns c
's source point.
c
is a point, a segment or a ray. Line_2 CGAL::Arr_linear_traits_2< Kernel >::Curve_2::supporting_line | ( | ) | const |
returns the supporting line of c
.
c
is not a point (a degenerate curve). Point_2 CGAL::Arr_linear_traits_2< Kernel >::Curve_2::target | ( | ) | const |
returns c
's target point.
c
is a point or a segment.