pub struct StaticFilter { /* private fields */ }Expand description
Precomputed error bounds for a declared coordinate range.
Construct once per model, reuse across every predicate call.
Implementations§
Source§impl StaticFilter
impl StaticFilter
Sourcepub fn new(bound: f64) -> Option<StaticFilter>
pub fn new(bound: f64) -> Option<StaticFilter>
Build bounds valid for coordinates with |x| <= bound.
Returns None for a non-finite or non-positive bound, and for a bound
so large that the derived error bound is not finite: in both cases no
sign could be certified, and returning a filter that always defers
would hide the configuration error.
Source§impl StaticFilter
impl StaticFilter
Sourcepub fn orient2d(self, a: DVec2, b: DVec2, c: DVec2) -> Option<Sign>
pub fn orient2d(self, a: DVec2, b: DVec2, c: DVec2) -> Option<Sign>
Try to settle orient2d with the precomputed bound.
None means “not settled”: either a point lies outside the declared
range, or the determinant is too small for the static bound. The caller
must fall back to the full predicate, which is always correct.
Trait Implementations§
Source§impl Clone for StaticFilter
impl Clone for StaticFilter
Source§fn clone(&self) -> StaticFilter
fn clone(&self) -> StaticFilter
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for StaticFilter
Source§impl Debug for StaticFilter
impl Debug for StaticFilter
Source§impl PartialEq for StaticFilter
impl PartialEq for StaticFilter
impl StructuralPartialEq for StaticFilter
Auto Trait Implementations§
impl Freeze for StaticFilter
impl RefUnwindSafe for StaticFilter
impl Send for StaticFilter
impl Sync for StaticFilter
impl Unpin for StaticFilter
impl UnsafeUnpin for StaticFilter
impl UnwindSafe for StaticFilter
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more