Enum usvg::filter::TransferFunction
source · [−]pub enum TransferFunction {
Identity,
Table(Vec<f64>),
Discrete(Vec<f64>),
Linear {
slope: f64,
intercept: f64,
},
Gamma {
amplitude: f64,
exponent: f64,
offset: f64,
},
}
Expand description
A transfer function used by FeComponentTransfer
.
https://www.w3.org/TR/SVG11/filters.html#transferFuncElements
Variants
Identity
Keeps a component as is.
Table(Vec<f64>)
Applies a linear interpolation to a component.
The number list can be empty.
Discrete(Vec<f64>)
Applies a step function to a component.
The number list can be empty.
Linear
Applies a linear shift to a component.
Gamma
Applies an exponential shift to a component.
Trait Implementations
sourceimpl Clone for TransferFunction
impl Clone for TransferFunction
sourcefn clone(&self) -> TransferFunction
fn clone(&self) -> TransferFunction
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
Auto Trait Implementations
impl RefUnwindSafe for TransferFunction
impl Send for TransferFunction
impl Sync for TransferFunction
impl Unpin for TransferFunction
impl UnwindSafe for TransferFunction
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more