[][src]Struct resize::Filter

pub struct Filter { /* fields omitted */ }

Resampling filter.

Implementations

impl Filter[src]

#[must_use]pub fn new(kernel: Box<dyn Fn(f32) -> f32>, support: f32) -> Self[src]

Create a new filter.

Examples

use resize::Filter;
fn kernel(x: f32) -> f32 { f32::max(1.0 - x.abs(), 0.0) }
let filter = Filter::new(Box::new(kernel), 1.0);

#[must_use]pub fn new_cubic(b: f32, c: f32) -> Self[src]

👎 Deprecated:

use Type enum

Helper to create Cubic filter with custom B and C parameters.

#[must_use]pub fn new_lanczos(radius: f32) -> Self[src]

👎 Deprecated:

use Type enum

Helper to create Lanczos filter with custom radius.

Auto Trait Implementations

impl !RefUnwindSafe for Filter

impl !Send for Filter

impl !Sync for Filter

impl Unpin for Filter

impl !UnwindSafe for Filter

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.