|
| constexpr | Line ()=default |
| | Creates the degenerate line (0,0)--(0,0).
|
| constexpr | Line (PointType first, PointType second) |
| | Creates a line from two defining points.
|
| constexpr | Line (NumberType x1, NumberType y1, NumberType x2, NumberType y2) |
| | Creates a line from four coordinates.
|
template<class A>
requires (detail::has_label_v<LabelType> && std::constructible_from<LabelType, A&&>) |
| constexpr | Line (PointType first, PointType second, A &&label) |
| | Creates a line from two defining points and stores a label.
|
template<class A>
requires (detail::has_label_v<LabelType> && std::constructible_from<LabelType, A&&>) |
| constexpr | Line (NumberType x1, NumberType y1, NumberType x2, NumberType y2, A &&label) |
| | Same as the four-coordinate constructor, and stores a label.
|
template<PointConcept OtherPointType, class OtherLabelType>
requires (std::constructible_from<PointType, const OtherPointType&>) |
| constexpr | Line (const Line< OtherPointType, OtherLabelType > &other) |
| | Converts a line with a different point and/or label type.
|
template<PointConcept OtherPointType, class OtherLabelType>
requires (std::constructible_from<PointType, const OtherPointType&>) |
| constexpr Line & | operator= (const Line< OtherPointType, OtherLabelType > &other) |
| | Assigns from a line with compatible point and label types.
|
| constexpr const PointType & | operator[] (std::size_t index) const |
| | Returns defining point 0 or 1.
|
| constexpr const PointType & | get (std::ptrdiff_t index) const |
| | Cyclic access: same as operator[] but index is taken modulo size(); negative indices wrap from the end.
|
| constexpr std::ptrdiff_t | index (const PointType &point) const |
| | Returns the smallest index i with (*this)[i] == point, or -1 if no defining point equals point.
|
| constexpr const PointType & | min () const |
| | Returns the smallest stored defining point.
|
| constexpr const PointType & | max () const |
| | Returns the largest stored defining point.
|
| constexpr auto | begin () const |
| | Returns an iterator to the first defining point.
|
| constexpr auto | cbegin () const |
| | Returns an iterator to the first defining point.
|
| constexpr auto | end () const |
| | Returns an iterator past the last defining point.
|
| constexpr auto | cend () const |
| | Returns an iterator past the last defining point.
|
| constexpr bool | operator== (const Line &other) const |
| | Tests geometric equality of two lines.
|
| template<AnyShapeConcept OtherShape> |
| constexpr bool | samePointSet (const OtherShape &other) const |
| | Tests whether another shape defines exactly the same point set.
|
| constexpr auto | operator<=> (const Line &other) const |
| | Provides an ordering compatible with geometric equality.
|
template<class A = LabelType>
requires (detail::has_label_v<A>) |
| constexpr A & | label () const |
| | Returns the line label.
|
| template<PointConcept OtherPoint> |
| constexpr Segment< PointType > | asSegmentFor (const Rectangle< OtherPoint > &rect) const |
| | Returns the segment that intersects r the same way as this line.
|
| constexpr HalfplaneIntersection< PointType > | asHalfplaneIntersection () const |
| | Returns the line as a (degenerate) half-plane intersection.
|
| template<class ResultNumber = division_result_t<NumberType>> |
| constexpr Point< ResultNumber, typename PointType::LabelType > | dual () const |
| | Returns the dual point.
|
| template<class ResultNumber = division_result_t<NumberType>> |
| constexpr Point< ResultNumber, typename PointType::LabelType > | polar () const |
| | Returns the polar point.
|
| template<class ResultNumber = NumberType> |
| constexpr ResultNumber | area () const |
| | Returns the area of the line.
|
| constexpr NumberType | twiceArea () const |
| | Returns twice the area of the line.
|
| constexpr Line | rotated90 (int k=1) const |
| | Returns the line rotated by 90k degrees around the origin.
|
| constexpr void | rotate90 (int k=1) |
| | Rotates the line by 90k degrees around the origin in place.
|
| template<class OtherNumber> |
| constexpr Line | scaledUpX (const OtherNumber scalar) const |
| | Returns the line with its x-coordinates multiplied by a factor.
|
| template<class OtherNumber> |
| constexpr void | scaleUpX (const OtherNumber scalar) |
| | Multiplies the line's x-coordinates by a factor in place.
|
| template<class OtherNumber> |
| constexpr Line | scaledUpY (const OtherNumber scalar) const |
| | Returns the line with its y-coordinates multiplied by a factor.
|
| template<class OtherNumber> |
| constexpr void | scaleUpY (const OtherNumber scalar) |
| | Multiplies the line's y-coordinates by a factor in place.
|
| template<class OtherNumber> |
| constexpr Line | scaledDownX (const OtherNumber scalar) const |
| | Returns the line with its x-coordinates divided by a divisor.
|
| template<class OtherNumber> |
| constexpr void | scaleDownX (const OtherNumber scalar) |
| | Divides the line's x-coordinates by a divisor in place.
|
| template<class OtherNumber> |
| constexpr Line | scaledDownY (const OtherNumber scalar) const |
| | Returns the line with its y-coordinates divided by a divisor.
|
| template<class OtherNumber> |
| constexpr void | scaleDownY (const OtherNumber scalar) |
| | Divides the line's y-coordinates by a divisor in place.
|
| constexpr bool | isDegenerate () const |
| | Returns whether the defining points coincide.
|
| constexpr bool | isUndefined () const |
| | Returns whether the line is degenerate without collapsing to a point or to a segment.
|
| constexpr bool | isVertical () const |
| | Returns whether the line is vertical.
|
| constexpr bool | isHorizontal () const |
| | Returns whether the line is horizontal.
|
| template<PointConcept OtherPoint> |
| constexpr bool | verticesContain (const OtherPoint &point) const |
| | Returns whether the given point is one of the stored defining points.
|
| template<PointConcept OtherPoint> |
| constexpr bool | boundaryContains (const OtherPoint &point) const |
| | Tests whether this shape's boundary contains the other shape (∂A ⊇ B).
|
| template<SegmentConcept OtherSegment> |
| constexpr bool | boundaryContains (const OtherSegment &) const |
| | Tests whether this shape's boundary contains the other shape (∂A ⊇ B).
|
| template<OrientedSegmentConcept OtherOrientedSegment> |
| constexpr bool | boundaryContains (const OtherOrientedSegment &) const |
| | Tests whether this shape's boundary contains the other shape (∂A ⊇ B).
|
| template<LineConcept OtherLine> |
| constexpr bool | boundaryContains (const OtherLine &) const |
| | Tests whether this shape's boundary contains the other shape (∂A ⊇ B).
|
| template<OrientedLineConcept OtherOrientedLine> |
| constexpr bool | boundaryContains (const OtherOrientedLine &) const |
| | Tests whether this shape's boundary contains the other shape (∂A ⊇ B).
|
| template<RayConcept OtherRay> |
| constexpr bool | boundaryContains (const OtherRay &) const |
| | Tests whether this shape's boundary contains the other shape (∂A ⊇ B).
|
| template<HalfplaneConcept OtherHalfplane> |
| constexpr bool | boundaryContains (const OtherHalfplane &) const |
| | Tests whether this shape's boundary contains the other shape (∂A ⊇ B).
|
| template<RectangleConcept OtherRectangle> |
| constexpr bool | boundaryContains (const OtherRectangle &) const |
| | Tests whether this shape's boundary contains the other shape (∂A ⊇ B).
|
| template<TriangleConcept OtherTriangle> |
| constexpr bool | boundaryContains (const OtherTriangle &) const |
| | Tests whether this shape's boundary contains the other shape (∂A ⊇ B).
|
| template<ConvexConcept OtherConvex> |
| constexpr bool | boundaryContains (const OtherConvex &) const |
| | Tests whether this shape's boundary contains the other shape (∂A ⊇ B).
|
| template<PolygonConcept OtherPolygon> |
| constexpr bool | boundaryContains (const OtherPolygon &) const |
| | Tests whether this shape's boundary contains the other shape (∂A ⊇ B).
|
| template<DiskConcept OtherDisk> |
| constexpr bool | boundaryContains (const OtherDisk &) const |
| | Tests whether this shape's boundary contains the other shape (∂A ⊇ B).
|
| template<PointConcept OtherPoint> |
| constexpr bool | contains (const OtherPoint &point) const |
| | Tests whether this shape contains the other shape (A ⊇ B).
|
| template<LineConcept OtherLine> |
| constexpr bool | contains (const OtherLine &other) const |
| | Tests whether this shape contains the other shape (A ⊇ B).
|
| template<SegmentConcept OtherSegment> |
| constexpr bool | contains (const OtherSegment &other) const |
| | Tests whether this shape contains the other shape (A ⊇ B).
|
| template<OrientedSegmentConcept OtherOrientedSegment> |
| constexpr bool | contains (const OtherOrientedSegment &other) const |
| | Tests whether this shape contains the other shape (A ⊇ B).
|
| template<OrientedLineConcept OtherOrientedLine> |
| constexpr bool | contains (const OtherOrientedLine &other) const |
| | Tests whether this shape contains the other shape (A ⊇ B).
|
| template<RayConcept OtherRay> |
| constexpr bool | contains (const OtherRay &other) const |
| | Tests whether this shape contains the other shape (A ⊇ B).
|
| template<HalfplaneConcept OtherHalfplane> |
| constexpr bool | contains (const OtherHalfplane &other) const |
| | Tests whether this shape contains the other shape (A ⊇ B).
|
| template<RectangleConcept OtherRectangle> |
| constexpr bool | contains (const OtherRectangle &other) const |
| | Tests whether this shape contains the other shape (A ⊇ B).
|
| template<TriangleConcept OtherTriangle> |
| constexpr bool | contains (const OtherTriangle &other) const |
| | Tests whether this shape contains the other shape (A ⊇ B).
|
| template<ConvexConcept OtherConvex> |
| constexpr bool | contains (const OtherConvex &other) const |
| | Tests whether this shape contains the other shape (A ⊇ B).
|
| template<PolygonConcept OtherPolygon> |
| constexpr bool | contains (const OtherPolygon &other) const |
| | Tests whether this shape contains the other shape (A ⊇ B).
|
| template<DiskConcept OtherDisk> |
| constexpr bool | contains (const OtherDisk &other) const |
| | Tests whether this shape contains the other shape (A ⊇ B).
|
| constexpr bool | contains (const Shape< PointType > &other) const |
| | Tests whether this shape contains the other shape (A ⊇ B).
|
| constexpr bool | boundaryContains (const Shape< PointType > &other) const |
| | Tests whether this shape's boundary contains the other shape (∂A ⊇ B).
|
| template<class EmptyPoint> |
| constexpr bool | contains (const EmptyShape< EmptyPoint > &) const |
| | Tests whether this shape contains the other shape (A ⊇ B).
|
| template<class EmptyPoint> |
| constexpr bool | boundaryContains (const EmptyShape< EmptyPoint > &) const |
| | Tests whether this shape's boundary contains the other shape (∂A ⊇ B).
|
| template<class EmptyPoint> |
| constexpr bool | interiorContains (const EmptyShape< EmptyPoint > &) const |
| | Tests whether this shape's interior contains the other shape (A∖∂A ⊇ B).
|
| template<class EmptyPoint> |
| constexpr bool | separates (const EmptyShape< EmptyPoint > &) const |
| | Tests whether removing this shape disconnects the other shape (B∖A is disconnected).
|
| template<PointConcept OtherPoint> |
| constexpr bool | interiorContains (const OtherPoint &point) const |
| | Tests whether this shape's interior contains the other shape (A∖∂A ⊇ B).
|
| template<LineConcept OtherLine> |
| constexpr bool | interiorContains (const OtherLine &other) const |
| | Tests whether this shape's interior contains the other shape (A∖∂A ⊇ B).
|
| template<SegmentConcept OtherSegment> |
| constexpr bool | interiorContains (const OtherSegment &other) const |
| | Tests whether this shape's interior contains the other shape (A∖∂A ⊇ B).
|
| template<OrientedSegmentConcept OtherOrientedSegment> |
| constexpr bool | interiorContains (const OtherOrientedSegment &other) const |
| | Tests whether this shape's interior contains the other shape (A∖∂A ⊇ B).
|
| template<OrientedLineConcept OtherOrientedLine> |
| constexpr bool | interiorContains (const OtherOrientedLine &other) const |
| | Tests whether this shape's interior contains the other shape (A∖∂A ⊇ B).
|
| template<RayConcept OtherRay> |
| constexpr bool | interiorContains (const OtherRay &other) const |
| | Tests whether this shape's interior contains the other shape (A∖∂A ⊇ B).
|
| template<HalfplaneConcept OtherHalfplane> |
| constexpr bool | interiorContains (const OtherHalfplane &other) const |
| | Tests whether this shape's interior contains the other shape (A∖∂A ⊇ B).
|
| template<RectangleConcept OtherRectangle> |
| constexpr bool | interiorContains (const OtherRectangle &other) const |
| | Tests whether this shape's interior contains the other shape (A∖∂A ⊇ B).
|
| template<TriangleConcept OtherTriangle> |
| constexpr bool | interiorContains (const OtherTriangle &other) const |
| | Tests whether this shape's interior contains the other shape (A∖∂A ⊇ B).
|
| template<PointConcept OtherPoint> |
| constexpr bool | collinear (const OtherPoint &point) const |
| | Returns whether the line interior contains the given point.
|
| template<SegmentConcept OtherSegment> |
| constexpr bool | collinear (const OtherSegment &other) const |
| | Returns whether the given segment is collinear with the line.
|
| template<OrientedSegmentConcept OtherOrientedSegment> |
| constexpr bool | collinear (const OtherOrientedSegment &other) const |
| | Returns whether the given oriented segment is collinear with the line.
|
| template<LineConcept OtherLine> |
| constexpr bool | collinear (const OtherLine &other) const |
| | Returns whether another line is collinear with this line.
|
| template<OrientedLineConcept OtherOrientedLine> |
| constexpr bool | collinear (const OtherOrientedLine &other) const |
| | Returns whether an oriented line is collinear with this line.
|
| template<RayConcept OtherRay> |
| constexpr bool | collinear (const OtherRay &other) const |
| | Returns whether a ray is collinear with this line.
|
| template<class ResultNumber = division_result_t<NumberType>> |
| constexpr ResultNumber | slope () const |
| | Returns the slope of the line.
|
| template<class ResultNumber = division_result_t<NumberType>, class OtherNumber> |
| constexpr std::optional< ResultNumber > | yAtX (const OtherNumber &x) const |
| | Returns the y-coordinate of the line at a given x-coordinate, if defined.
|
| template<class ResultNumber = division_result_t<NumberType>, class OtherNumber> |
| constexpr std::optional< ResultNumber > | xAtY (const OtherNumber &y) const |
| | Returns the x-coordinate of the line at a given y-coordinate, if defined.
|
| constexpr Halfplane< PointType > | halfplaneAbove () const |
| | Returns the half-plane geometrically above this line.
|
| constexpr Halfplane< PointType > | halfplaneBelow () const |
| | Returns the half-plane geometrically below this line.
|
| template<LineConcept OtherLine> |
| constexpr bool | parallel (const OtherLine &other) const |
| | Returns whether another line is parallel to this line.
|
| template<SegmentConcept OtherSegment> |
| constexpr bool | parallel (const OtherSegment &other) const |
| | Returns whether a segment is parallel to this line.
|
| template<OrientedSegmentConcept OtherOrientedSegment> |
| constexpr bool | parallel (const OtherOrientedSegment &other) const |
| | Returns whether an oriented segment is parallel to this line.
|
| template<OrientedLineConcept OtherOrientedLine> |
| constexpr bool | parallel (const OtherOrientedLine &other) const |
| | Returns whether an oriented line is parallel to this line.
|
| template<RayConcept OtherRay> |
| constexpr bool | parallel (const OtherRay &other) const |
| | Returns whether a ray is parallel to this line.
|
| template<PointConcept OtherPoint> |
| constexpr bool | intersects (const OtherPoint &other) const |
| | Tests whether this shape and the other shape intersect (A ∩ B ≠ ∅).
|
| template<LineConcept OtherLine> |
| constexpr bool | intersects (const OtherLine &other) const |
| | Tests whether this shape and the other shape intersect (A ∩ B ≠ ∅).
|
| template<SegmentConcept OtherSegment> |
| constexpr bool | intersects (const OtherSegment &other) const |
| | Tests whether this shape and the other shape intersect (A ∩ B ≠ ∅).
|
| template<OrientedSegmentConcept OtherOrientedSegment> |
| constexpr bool | intersects (const OtherOrientedSegment &other) const |
| | Tests whether this shape and the other shape intersect (A ∩ B ≠ ∅).
|
| constexpr bool | intersects (const Shape< PointType > &other) const |
| | Tests whether this shape and the other shape intersect (A ∩ B ≠ ∅).
|
template<typename OtherShape>
requires (!PointConcept<OtherShape> && detail::shapeRank<OtherShape> > detail::shapeRank<Line>) |
| constexpr bool | intersects (const OtherShape &other) const |
| | Tests whether this shape and the other shape intersect (A ∩ B ≠ ∅).
|
| template<class EmptyPoint> |
| constexpr bool | intersects (const EmptyShape< EmptyPoint > &) const |
| | Tests whether this shape and the other shape intersect (A ∩ B ≠ ∅).
|
| template<PointConcept OtherPoint> |
| constexpr bool | interiorsIntersect (const OtherPoint &other) const |
| | Tests whether the interiors of the two shapes intersect ((A∖∂A) ∩ (B∖∂B) ≠ ∅).
|
| template<LineConcept OtherLine> |
| constexpr bool | interiorsIntersect (const OtherLine &other) const |
| | Tests whether the interiors of the two shapes intersect ((A∖∂A) ∩ (B∖∂B) ≠ ∅).
|
| template<SegmentConcept OtherSegment> |
| constexpr bool | interiorsIntersect (const OtherSegment &other) const |
| | Tests whether the interiors of the two shapes intersect ((A∖∂A) ∩ (B∖∂B) ≠ ∅).
|
| template<OrientedSegmentConcept OtherOrientedSegment> |
| constexpr bool | interiorsIntersect (const OtherOrientedSegment &other) const |
| | Tests whether the interiors of the two shapes intersect ((A∖∂A) ∩ (B∖∂B) ≠ ∅).
|
template<typename OtherShape>
requires (!PointConcept<OtherShape> && detail::shapeRank<OtherShape> > detail::shapeRank<Line>) |
| constexpr bool | interiorsIntersect (const OtherShape &other) const |
| | Tests whether the interiors of the two shapes intersect ((A∖∂A) ∩ (B∖∂B) ≠ ∅).
|
| template<class EmptyPoint> |
| constexpr bool | interiorsIntersect (const EmptyShape< EmptyPoint > &) const |
| | Tests whether the interiors of the two shapes intersect ((A∖∂A) ∩ (B∖∂B) ≠ ∅).
|
| constexpr bool | interiorsIntersect (const Shape< PointType > &other) const |
| | Tests whether the interiors of the two shapes intersect ((A∖∂A) ∩ (B∖∂B) ≠ ∅).
|
| template<LineConcept OtherLine> |
| constexpr bool | crosses (const OtherLine &other) const |
| | Tests whether the two shapes mutually separate each other (each disconnects the other).
|
| template<PointConcept OtherPoint> |
| constexpr bool | crosses (const OtherPoint &other) const |
| | Tests whether the two shapes mutually separate each other (each disconnects the other).
|
| template<SegmentConcept OtherSegment> |
| constexpr bool | crosses (const OtherSegment &other) const |
| | Tests whether the two shapes mutually separate each other (each disconnects the other).
|
| template<OrientedSegmentConcept OtherOrientedSegment> |
| constexpr bool | crosses (const OtherOrientedSegment &other) const |
| | Tests whether the two shapes mutually separate each other (each disconnects the other).
|
template<typename OtherShape>
requires (!PointConcept<OtherShape> && detail::shapeRank<OtherShape> > detail::shapeRank<Line>) |
| constexpr bool | crosses (const OtherShape &other) const |
| | Tests whether the two shapes mutually separate each other (each disconnects the other).
|
| template<class EmptyPoint> |
| constexpr bool | crosses (const EmptyShape< EmptyPoint > &) const |
| | Tests whether the two shapes mutually separate each other (each disconnects the other).
|
| constexpr bool | crosses (const Shape< PointType > &other) const |
| | Tests whether the two shapes mutually separate each other (each disconnects the other).
|
| template<PointConcept OtherPoint> |
| constexpr bool | separates (const OtherPoint &other) const |
| | Tests whether removing this shape disconnects the other shape (B∖A is disconnected).
|
| template<SegmentConcept OtherSegment> |
| constexpr bool | separates (const OtherSegment &other) const |
| | Tests whether removing this shape disconnects the other shape (B∖A is disconnected).
|
| template<OrientedSegmentConcept OtherOrientedSegment> |
| constexpr bool | separates (const OtherOrientedSegment &other) const |
| | Tests whether removing this shape disconnects the other shape (B∖A is disconnected).
|
| template<LineConcept OtherLine> |
| constexpr bool | separates (const OtherLine &other) const |
| | Tests whether removing this shape disconnects the other shape (B∖A is disconnected).
|
| template<OrientedLineConcept OtherOrientedLine> |
| constexpr bool | separates (const OtherOrientedLine &other) const |
| | Tests whether removing this shape disconnects the other shape (B∖A is disconnected).
|
| template<RayConcept OtherRay> |
| constexpr bool | separates (const OtherRay &other) const |
| | Tests whether removing this shape disconnects the other shape (B∖A is disconnected).
|
| template<RectangleConcept OtherRectangle> |
| constexpr bool | separates (const OtherRectangle &other) const |
| | Tests whether removing this shape disconnects the other shape (B∖A is disconnected).
|
| template<TriangleConcept OtherTriangle> |
| constexpr bool | separates (const OtherTriangle &other) const |
| | Tests whether removing this shape disconnects the other shape (B∖A is disconnected).
|
| template<HalfplaneConcept OtherHalfplane> |
| constexpr bool | separates (const OtherHalfplane &other) const |
| | Tests whether removing this shape disconnects the other shape (B∖A is disconnected).
|
| template<ConvexConcept OtherConvex> |
| constexpr bool | separates (const OtherConvex &other) const |
| | Tests whether removing this shape disconnects the other shape (B∖A is disconnected).
|
| template<DiskConcept OtherDisk> |
| constexpr bool | separates (const OtherDisk &other) const |
| | Tests whether removing this shape disconnects the other shape (B∖A is disconnected).
|
| template<PolygonConcept OtherPolygon> |
| constexpr bool | separates (const OtherPolygon &other) const |
| | Tests whether removing this shape disconnects the other shape (B∖A is disconnected).
|
| template<MonotoneChainConcept OtherChain> |
| constexpr bool | contains (const OtherChain &other) const |
| | Tests whether this shape contains the other shape (A ⊇ B).
|
| template<MonotoneChainConcept OtherChain> |
| constexpr bool | boundaryContains (const OtherChain &) const |
| | Tests whether this shape's boundary contains the other shape (∂A ⊇ B).
|
| template<MonotoneChainConcept OtherChain> |
| constexpr bool | interiorContains (const OtherChain &other) const |
| | Tests whether this shape's interior contains the other shape (A∖∂A ⊇ B).
|
| template<MonotoneChainConcept OtherChain> |
| constexpr bool | separates (const OtherChain &other) const |
| | Tests whether removing this shape disconnects the other shape (B∖A is disconnected).
|
| template<PolylineConcept OtherPolyline> |
| constexpr bool | contains (const OtherPolyline &other) const |
| | Tests whether this shape contains the other shape (A ⊇ B).
|
| template<PolylineConcept OtherPolyline> |
| constexpr bool | boundaryContains (const OtherPolyline &) const |
| | Tests whether this shape's boundary contains the other shape (∂A ⊇ B).
|
| template<PolylineConcept OtherPolyline> |
| constexpr bool | interiorContains (const OtherPolyline &other) const |
| | Tests whether this shape's interior contains the other shape (A∖∂A ⊇ B).
|
| template<PolylineConcept OtherPolyline> |
| constexpr bool | separates (const OtherPolyline &other) const |
| | Tests whether removing this shape disconnects the other shape (B∖A is disconnected).
|
| template<HalfplaneIntersectionConcept OtherRegion> |
| constexpr bool | contains (const OtherRegion &other) const |
| | Tests whether this shape contains the other shape (A ⊇ B).
|
| template<HalfplaneIntersectionConcept OtherRegion> |
| constexpr bool | boundaryContains (const OtherRegion &other) const |
| | Tests whether this shape's boundary contains the other shape (∂A ⊇ B).
|
| template<HalfplaneIntersectionConcept OtherRegion> |
| constexpr bool | interiorContains (const OtherRegion &other) const |
| | Tests whether this shape's interior contains the other shape (A∖∂A ⊇ B).
|
| template<HalfplaneIntersectionConcept OtherRegion> |
| constexpr bool | separates (const OtherRegion &other) const |
| | Tests whether removing this shape disconnects the other shape (B∖A is disconnected).
|
| template<PolygonWithHolesConcept OtherRegion> |
| constexpr bool | contains (const OtherRegion &other) const |
| | Tests whether this shape contains the other shape (A ⊇ B).
|
| template<PolygonWithHolesConcept OtherRegion> |
| constexpr bool | boundaryContains (const OtherRegion &other) const |
| | Tests whether this shape's boundary contains the other shape (∂A ⊇ B).
|
| template<PolygonWithHolesConcept OtherRegion> |
| constexpr bool | interiorContains (const OtherRegion &other) const |
| | Tests whether this shape's interior contains the other shape (A∖∂A ⊇ B).
|
| template<PolygonWithHolesConcept OtherRegion> |
| bool | separates (const OtherRegion &other) const |
| | Tests whether removing this shape disconnects the other shape (B∖A is disconnected).
|
| template<PolygonSetConcept OtherSet> |
| constexpr bool | contains (const OtherSet &other) const |
| | Tests whether this shape contains the other shape (A ⊇ B).
|
| template<PolygonSetConcept OtherSet> |
| constexpr bool | boundaryContains (const OtherSet &other) const |
| | Tests whether this shape's boundary contains the other shape (∂A ⊇ B).
|
| template<PolygonSetConcept OtherSet> |
| constexpr bool | interiorContains (const OtherSet &other) const |
| | Tests whether this shape's interior contains the other shape (A∖∂A ⊇ B).
|
| template<PolygonSetConcept OtherSet> |
| bool | separates (const OtherSet &other) const |
| | Tests whether removing this shape disconnects the other shape (B∖A is disconnected).
|
| constexpr bool | separates (const Shape< PointType > &other) const |
| | Tests whether removing this shape disconnects the other shape (B∖A is disconnected).
|
| template<DiskConcept OtherDisk> |
| constexpr bool | interiorContains (const OtherDisk &other) const |
| | Tests whether this shape's interior contains the other shape (A∖∂A ⊇ B).
|
| template<ConvexConcept OtherConvex> |
| constexpr bool | interiorContains (const OtherConvex &other) const |
| | Tests whether this shape's interior contains the other shape (A∖∂A ⊇ B).
|
| template<PolygonConcept OtherPolygon> |
| constexpr bool | interiorContains (const OtherPolygon &other) const |
| | Tests whether this shape's interior contains the other shape (A∖∂A ⊇ B).
|
| template<class ResultNumber = NumberType, PointConcept OtherPoint> |
| constexpr std::optional< Point< ResultNumber, typename PointType::LabelType > > | intersection (const OtherPoint &other) const |
| | Returns the intersection of the two shapes (A ∩ B), empty when they are disjoint.
|
| template<class ResultNumber = division_result_t<NumberType>, LineConcept OtherLine> |
| constexpr std::optional< std::variant< Point< ResultNumber, typename PointType::LabelType >, Line< Point< ResultNumber, typename PointType::LabelType > > > > | intersection (const OtherLine &other) const |
| | Returns the intersection of the two shapes (A ∩ B), empty when they are disjoint.
|
| template<class ResultNumber = division_result_t<NumberType>, SegmentConcept OtherSegment> |
| constexpr auto | intersection (const OtherSegment &other) const |
| | Returns the intersection of the two shapes (A ∩ B), empty when they are disjoint.
|
| template<class ResultNumber = division_result_t<NumberType>, OrientedSegmentConcept OtherOrientedSegment> |
| constexpr auto | intersection (const OtherOrientedSegment &other) const |
| | Returns the intersection of the two shapes (A ∩ B), empty when they are disjoint.
|
template<class ResultNumber = division_result_t<NumberType>, typename OtherShape>
requires (!PointConcept<OtherShape> && (detail::shapeRank<OtherShape> > detail::shapeRank<Line>) && requires(const OtherShape& o,
const Line& self) { o.template intersection<ResultNumber>(self); }) |
| constexpr auto | intersection (const OtherShape &other) const |
| | Returns the intersection of the two shapes (A ∩ B), empty when they are disjoint.
|
| template<class ResultNumber = NumberType, class EmptyPoint> |
| constexpr EmptyShape< EmptyPoint > | intersection (const EmptyShape< EmptyPoint > &) const |
| | Returns the intersection of the two shapes (A ∩ B), empty when they are disjoint.
|
| template<class ResultNumber = division_result_t<NumberType>, PointConcept OtherPoint> |
| constexpr auto | squaredDistance (const OtherPoint &point) const |
| | Returns the squared Euclidean distance to the given shape.
|
| template<class ResultNumber = division_result_t<NumberType>, LineConcept OtherLine> |
| constexpr auto | squaredDistance (const OtherLine &other) const |
| | Returns the squared Euclidean distance to the given shape.
|
| template<class ResultNumber = division_result_t<NumberType>, SegmentConcept OtherSegment> |
| constexpr auto | squaredDistance (const OtherSegment &other) const |
| | Returns the squared Euclidean distance to the given shape.
|
| template<class ResultNumber = division_result_t<NumberType>, OrientedSegmentConcept OtherOrientedSegment> |
| constexpr auto | squaredDistance (const OtherOrientedSegment &other) const |
| | Returns the squared Euclidean distance to the given shape.
|
template<class ResultNumber = division_result_t<NumberType>, typename OtherShape>
requires ((detail::shapeRank<OtherShape> > detail::shapeRank<Line>) && requires(const OtherShape& o, const Line& self)
{ o.template squaredDistance<ResultNumber>(self); }) |
| constexpr auto | squaredDistance (const OtherShape &other) const |
| | Returns the squared Euclidean distance to the given shape.
|
| template<class ResultNumber = double, class DiskPointType, class DiskLabel> |
| detail::floating_result_t< ResultNumber > | squaredDistance (const Disk< DiskPointType, DiskLabel > &disk) const |
| | Returns the squared Euclidean distance to a disk.
|
template<class ResultNumber = division_result_t<NumberType>, class OtherShape>
requires detail::ClosestPointsPairConcept<Line<PointType_, TLabel>, OtherShape> |
| constexpr auto | closestPoints (const OtherShape &other) const |
| | Returns the pair of points realizing the distance, nothing when the shapes meet.
|
| template<class ResultNumber = division_result_t<NumberType>, PointConcept OtherPoint> |
| constexpr auto | distanceL1 (const OtherPoint &point) const |
| | Returns the Manhattan (L1) distance to the given shape.
|
| template<class ResultNumber = division_result_t<NumberType>, LineConcept OtherLine> |
| constexpr auto | distanceL1 (const OtherLine &other) const |
| | Returns the Manhattan (L1) distance to the given shape.
|
| template<class ResultNumber = division_result_t<NumberType>, SegmentConcept OtherSegment> |
| constexpr auto | distanceL1 (const OtherSegment &other) const |
| | Returns the Manhattan (L1) distance to the given shape.
|
| template<class ResultNumber = division_result_t<NumberType>, OrientedSegmentConcept OtherOrientedSegment> |
| constexpr auto | distanceL1 (const OtherOrientedSegment &other) const |
| | Returns the Manhattan (L1) distance to the given shape.
|
template<class ResultNumber = division_result_t<NumberType>, typename OtherShape>
requires ((detail::shapeRank<OtherShape> > detail::shapeRank<Line>) && requires(const OtherShape& o, const Line& self)
{ o.template distanceL1<ResultNumber>(self); }) |
| constexpr auto | distanceL1 (const OtherShape &other) const |
| | Returns the Manhattan (L1) distance to the given shape.
|
| template<class ResultNumber = division_result_t<NumberType>, PointConcept OtherPoint> |
| constexpr auto | intersection (const Shape< OtherPoint > &other) const |
| | Returns the intersection of the two shapes (A ∩ B), re-dispatching through the wrapper's own intersection.
|
| template<class ResultNumber = double, PointConcept OtherPoint> |
| constexpr auto | distanceL1 (const Shape< OtherPoint > &other) const |
| | Returns the distance to the given shape, using symmetry to re-dispatch through the wrapper's own distanceL1.
|
| template<class ResultNumber = division_result_t<NumberType>, PointConcept OtherPoint> |
| constexpr auto | distanceLInf (const OtherPoint &point) const |
| | Returns the Chebyshev (LInf) distance to the given shape.
|
| template<class ResultNumber = division_result_t<NumberType>, LineConcept OtherLine> |
| constexpr auto | distanceLInf (const OtherLine &other) const |
| | Returns the Chebyshev (LInf) distance to the given shape.
|
| template<class ResultNumber = division_result_t<NumberType>, SegmentConcept OtherSegment> |
| constexpr auto | distanceLInf (const OtherSegment &other) const |
| | Returns the Chebyshev (LInf) distance to the given shape.
|
| template<class ResultNumber = division_result_t<NumberType>, OrientedSegmentConcept OtherOrientedSegment> |
| constexpr auto | distanceLInf (const OtherOrientedSegment &other) const |
| | Returns the Chebyshev (LInf) distance to the given shape.
|
template<class ResultNumber = division_result_t<NumberType>, typename OtherShape>
requires ((detail::shapeRank<OtherShape> > detail::shapeRank<Line>) && requires(const OtherShape& o, const Line& self)
{ o.template distanceLInf<ResultNumber>(self); }) |
| constexpr auto | distanceLInf (const OtherShape &other) const |
| | Returns the Chebyshev (LInf) distance to the given shape.
|
| template<class ResultNumber = double, PointConcept OtherPoint> |
| constexpr auto | distanceLInf (const Shape< OtherPoint > &other) const |
| | Returns the distance to the given shape, using symmetry to re-dispatch through the wrapper's own distanceLInf.
|
template<class OtherShape>
requires MinkowskiSummableConcept<Line<PointType_, TLabel>, OtherShape> |
| constexpr auto | minkowskiSum (const OtherShape &other) const |
| | Returns the Minkowski sum of this shape and another (A ⊕ B).
|
template<class OtherShape>
requires MinkowskiSummableConcept<Line<PointType_, TLabel>, OtherShape> |
| constexpr auto | minkowskiErosion (const OtherShape &other) const |
| | Returns the Minkowski erosion of this shape by another (A ⊖ B).
|
| template<PointConcept OtherPoint> |
| constexpr Line & | operator+= (const OtherPoint &translation) |
| | Translates both defining points in place.
|
| template<PointConcept OtherPoint> |
| constexpr Line & | operator-= (const OtherPoint &translation) |
| | Translates both defining points by the opposite vector in place.
|
template<class Scalar>
requires (!detail::is_point_v<Scalar> && !TransformationConcept<Scalar>) |
| constexpr Line & | operator*= (const Scalar &scalar) |
| | Scales the line around the origin in place.
|
template<class Scalar>
requires (!detail::is_point_v<Scalar> && !TransformationConcept<Scalar>) |
| constexpr Line & | operator/= (const Scalar &scalar) |
| | Divides the line coordinates by a scalar in place.
|
| template<class ResultNumber = NumberType> |
| constexpr Point< ResultNumber > | pointInside () const |
| | Returns a point inside the line.
|
| template<class OtherShape> |
| constexpr bool | pointInsideInteriorContainedIn (const OtherShape &shape) const |
| | Tests whether some point in this shape's relative interior lies in the strict interior of shape.
|
| template<class ResultNumber> |
| constexpr auto | dualCoordinates () const |
| | Returns normalized dual-line coordinates for the supporting line.
|
| template<PointConcept OtherPoint> |
| constexpr Line< PointType, LabelType > & | operator+= (const OtherPoint &translation) |
| template<PointConcept OtherPoint> |
| constexpr Line< PointType, LabelType > & | operator-= (const OtherPoint &translation) |
template<class Scalar>
requires (!detail::is_point_v<Scalar> && !TransformationConcept<Scalar>) |
| constexpr Line< PointType, LabelType > & | operator*= (const Scalar &scalar) |
template<class Scalar>
requires (!detail::is_point_v<Scalar> && !TransformationConcept<Scalar>) |
| constexpr Line< PointType, LabelType > & | operator/= (const Scalar &scalar) |
| template<class OtherNumber> |
| constexpr Line< PointType, LabelType > | scaledUpX (const OtherNumber scalar) const |
| template<class OtherNumber> |
| constexpr Line< PointType, LabelType > | scaledUpY (const OtherNumber scalar) const |
| template<class OtherNumber> |
| constexpr Line< PointType, LabelType > | scaledDownX (const OtherNumber scalar) const |
| template<class OtherNumber> |
| constexpr Line< PointType, LabelType > | scaledDownY (const OtherNumber scalar) const |