Trait Interp2DStrategy

Source
pub trait Interp2DStrategy<Sd, Sx, Sy, D>
where Sd: Data, Sd::Elem: Num + PartialOrd + NumCast + Copy + Debug + Sub + Send, Sx: Data<Elem = Sd::Elem>, Sy: Data<Elem = Sd::Elem>, D: Dimension + RemoveAxis, D::Smaller: RemoveAxis, Self: Sized,
{ // Required method fn interp_into( &self, interpolator: &Interp2D<Sd, Sx, Sy, D, Self>, target: ArrayViewMut<'_, Sd::Elem, <D::Smaller as Dimension>::Smaller>, x: Sx::Elem, y: Sy::Elem, ) -> Result<(), InterpolateError>; }

Required Methods§

Source

fn interp_into( &self, interpolator: &Interp2D<Sd, Sx, Sy, D, Self>, target: ArrayViewMut<'_, Sd::Elem, <D::Smaller as Dimension>::Smaller>, x: Sx::Elem, y: Sy::Elem, ) -> Result<(), InterpolateError>

Interpolate the at position (x, y) into the target array. This is used internally by Interp2D.

When called by Interp2D the following properties are guaranteed:

  • The shape of the target array matches the shape of the data array (provided to the builder) with the first two axes removed.
  • x can be any valid Sx::Elem
  • y cna be any valid Sy::Elem

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl<Sd, Sx, Sy, D> Interp2DStrategy<Sd, Sx, Sy, D> for Bilinear
where Sd: Data, Sd::Elem: Num + PartialOrd + NumCast + Copy + Debug + Sub + Send, Sx: Data<Elem = Sd::Elem>, Sy: Data<Elem = Sd::Elem>, D: Dimension + RemoveAxis, D::Smaller: RemoveAxis,