pub fn region(
edges: &[Edge2],
inside: impl Fn([i64; 2]) -> bool,
) -> OgeomResult<Vec<Loop2>>Expand description
The boundary of the points whose winding counts inside accepts.
The loops are within half a cell’s diagonal of the exact boundary, a
cell being the power of two at or above 2^-38 of the widest extent of
the endpoints: at most 2^-37 of it.
The edges must form a closed chain in each count: at every endpoint the
weights of the edges arriving sum to those of the edges leaving. A
chain that is not closed has no counts, and its region is whatever the
walk from the unbounded face meets first. inside must reject [0, 0],
the counts of every point far away.
§Errors
OgeomError::Numeric if an endpoint
is not finite, and
OgeomError::Construction if
inside accepts [0, 0].