PointsFunc

Trait PointsFunc 

Source
pub trait PointsFunc {
    // Required method
    fn apply_points_func(
        &mut self,
        f: impl for<'a> Fn(&'a mut [DVec3]),
    ) -> &mut Self;

    // Provided methods
    fn apply_affine2(&mut self, affine: DAffine2) -> &mut Self { ... }
    fn apply_affine3(&mut self, affine: DAffine3) -> &mut Self { ... }
    fn apply_point_func(&mut self, f: impl Fn(&mut DVec3)) -> &mut Self { ... }
    fn apply_point_map(&mut self, f: impl Fn(DVec3) -> DVec3) -> &mut Self { ... }
    fn apply_complex_func(&mut self, f: impl Fn(&mut Complex64)) -> &mut Self { ... }
    fn apply_complex_map(
        &mut self,
        f: impl Fn(Complex64) -> Complex64,
    ) -> &mut Self { ... }
}
Expand description

A trait for items that can apply points function.

Required Methods§

Source

fn apply_points_func( &mut self, f: impl for<'a> Fn(&'a mut [DVec3]), ) -> &mut Self

Applying points function to an item

Provided Methods§

Source

fn apply_affine2(&mut self, affine: DAffine2) -> &mut Self

Applying affine transform in xy plane to an item

Source

fn apply_affine3(&mut self, affine: DAffine3) -> &mut Self

Applying affine transform to an item

Source

fn apply_point_func(&mut self, f: impl Fn(&mut DVec3)) -> &mut Self

Applying point function to an item

Source

fn apply_point_map(&mut self, f: impl Fn(DVec3) -> DVec3) -> &mut Self

Applying point function to an item

Source

fn apply_complex_func(&mut self, f: impl Fn(&mut Complex64)) -> &mut Self

Applying complex function to an item.

The point’s x and y coordinates will be used as real and imaginary parts of a complex number.

Source

fn apply_complex_map(&mut self, f: impl Fn(Complex64) -> Complex64) -> &mut Self

Applying complex function to an item.

The point’s x and y coordinates will be used as real and imaginary parts of a complex number.

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.

Implementations on Foreign Types§

Source§

impl PointsFunc for DVec3

Source§

fn apply_points_func( &mut self, f: impl for<'a> Fn(&'a mut [DVec3]), ) -> &mut Self

Source§

impl<T: PointsFunc> PointsFunc for [T]

Source§

fn apply_points_func( &mut self, f: impl for<'a> Fn(&'a mut [DVec3]), ) -> &mut Self

Implementors§