pub fn offset_polygon_miter(
polygon: &[(f64, f64)],
distance: f64,
miter_limit: f64,
) -> Vec<Vec<(f64, f64)>>Expand description
Offsets a simple polygon by distance with a configurable miter limit.
The miter limit controls how far a miter join can extend relative to the
offset distance. When the miter ratio at a vertex exceeds miter_limit,
a bevel join is inserted instead, preventing long spikes at acute angles.
§Arguments
polygon- A simple polygon as a slice of(f64, f64)verticesdistance- Offset distance (positive = outward, negative = inward)miter_limit- Maximum miter ratio before switching to bevel
§Returns
Vec of polygon rings. May be empty, single, or multiple rings.