# Module cavalier_contours::polyline

source · ## Expand description

This module has all the types and functions associated with polylines, polyline vertexes, and polyline segments.

## Modules§

- Internal polyline modules made public for visualization, benchmarking, and testing purposes.

## Structs§

- Open polyline slice created in the process of performing a polyline boolean operation.
- Result of performing a boolean operation between two polylines.
- Represents one of the polyline results from a boolean operation between two polylines.
- Result from calling PlineSource::closest_point.
- Represents a polyline intersect at a single point.
- Represents a collection of basic and overlapping polyline intersects.
- Struct to hold options parameters when performing polyline offset.
- Represents an overlapping polyline intersect segment.
- An iterator that traverses all segment vertex pair index positions.
- A polyline vertex is represented by an
`x`

,`y`

, and`bulge`

value. - A PlineView represents a partial selection or subpart of a source polyline without copying. This structure borrows a source polyline to access vertex data for iteration and operations.
- Structure to hold the minimum data required to create view as a partial selection over a source polyline. This structure is detached from the source polyline unlike PlineView.
- Basic polyline data representation that implements the core polyline traits: PlineSource, PlineSourceMut, and PlineCreation. See the traits documentation for all the polyline methods/operations available.
- An iterator that traverses polyline segments (as pairs of vertexes).
- Result from splitting a segment using seg_split_at_point.
- An iterator that traverses polyline vertexes.

## Enums§

- Boolean operation to apply to polylines.
- Information about what happened during the boolean operation.
- Represents a polyline intersect that may be either a PlineBasicIntersect or PlineOverlappingIntersect.
- Represents the orientation of a polyline.
- Holds the result of finding the intersect between two polyline segments.
- Enum to control which self intersects to include.
- Enum used for view data validation debugging and asserting.

## Traits§

- Trait representing a creatable source of polyline data. This trait acts as a mutable polyline source and also exposes associated functions for construction. This trait is used when new polylines need to be returned from a function.
- Trait for visiting polyline intersects.
- Trait for visiting polyline segments (two consecutive vertexes).
- Trait representing a readonly source of polyline data. This trait has all the methods and operations that can be performed on a readonly polyline.
- Trait representing a mutable source of polyline data. This trait has all the methods and operations that can be performed on a mutable polyline.
- Trait for visiting polyline vertexes.

## Functions§

- Finds the intersects between two polyline segments.
- Get the arc radius and center of an arc polyline segment defined by
`v1`

to`v2`

. Behavior undefined (may panic or return without error) if v1.bulge is zero. - Computes the axis aligned bounding box of a polyline segment defined by
`v1`

to`v2`

. - Find the closest point on a polyline segment defined by
`v1`

to`v2`

to`point`

given. If there are multiple closest points then one is chosen (which is chosen is not defined). - Computes a fast approximate axis aligned bounding box of a polyline segment defined by
`v1`

to`v2`

. - Calculate the path length of the polyline segment defined by
`v1`

to`v2`

. - Find the midpoint for the polyline segment defined by
`v1`

to`v2`

. - Splits a polyline segment defined by
`v1`

to`v2`

at the`point_on_seg`

given. Assumes the`point_on_seg`

lies on the segment. - Find the tangent direction vector on a polyline segment defined by
`v1`

to`v2`

at`point_on_seg`

.