rendiation icon indicating copy to clipboard operation
rendiation copied to clipboard

improve tolerance(or in other generic param's form) support in primitive intersection impl

Open mikialex opened this issue 4 years ago • 1 comments

mikialex avatar May 29 '20 15:05 mikialex

Motivation

  • Clippy complains float compare in intersections impl.
  • Raytracing need abstaction of epsilon
  • Picking need raycast param like screen space tolerance

Resolved by: IntersectAble now has third generic parameter to support params used for intersection

pub trait IntersectAble<Target, Result, Parameter = ()> {
  fn intersect(&self, other: &Target, param: &Parameter) -> Result;
}

mikialex avatar May 29 '20 15:05 mikialex