Skip to main content

Crate klayout_geom

Crate klayout_geom 

Source
Expand description

klayout-geom — geometric algorithms over klayout-core types.

Region is the central abstraction: a deterministic, merged set of polygons on a single conceptual layer. Boolean ops and sizing produce Regions; flattening a hierarchical (Library, CellId, LayerIndex) into a Region is the bridge to verification and routing.

Re-exports§

pub use boolean::difference;
pub use boolean::intersection;
pub use boolean::merge;
pub use boolean::union;
pub use boolean::xor;
pub use convex::convex_pieces;
pub use convex::decompose;
pub use convex::ear_clip;
pub use convex::Triangle;
pub use fracture::fracture;
pub use fracture::Trapezoid;
pub use edges::Edge;
pub use edges::Edges;
pub use path::path_to_polygon;
pub use region::Region;
pub use select::inside;
pub use select::interacting;
pub use select::not_interacting;
pub use select::not_overlapping;
pub use select::outside;
pub use select::overlapping;
pub use select::select_by_area;
pub use select::select_by_aspect_ratio;
pub use select::select_by_perimeter;
pub use select::with_text;
pub use simplify::simplify;
pub use simplify::simplify_open;
pub use simplify::simplify_ring;
pub use size::size;
pub use size::SizeJoin;

Modules§

boolean
Boolean ops on Regions, backed by i_overlay.
convex
Convex decomposition of polygons via ear-clipping.
edges
Edge collections — first-class edges as a complement to Region.
fracture
Mask-data fracturing — trapezoidalisation.
path
Path → Polygon rendering.
region
Region — a deterministic, normalized set of polygons on a single layer.
select
Selection / classification operators on Region — the core KLayout deck DSL primitives.
simplify
Polygon vertex-reduction via Douglas-Peucker.
size
Sizing (offset / Minkowski sum with a disk-equivalent).