pub trait Primitive<S, P>: Debugwhere
S: Field,
P: AffineSpace<S>,{
// Required methods
fn translate(&mut self, displacement: <P as AffineSpace<S>>::Translation);
fn scale(&mut self, scale: Positive<S>);
fn support(
&self,
direction: <<P as AffineSpace<S>>::Translation as VectorSpace<S>>::NonZero,
) -> (P, S);
}Available on crate feature
math-utils only.Expand description
Geometric primitives generic over dimension
Required Methods§
fn translate(&mut self, displacement: <P as AffineSpace<S>>::Translation)
fn scale(&mut self, scale: Positive<S>)
Sourcefn support(
&self,
direction: <<P as AffineSpace<S>>::Translation as VectorSpace<S>>::NonZero,
) -> (P, S)
fn support( &self, direction: <<P as AffineSpace<S>>::Translation as VectorSpace<S>>::NonZero, ) -> (P, S)
Returns the point with largeest dot product in search direction