pub struct Method {
pub curve: f32,
pub stretch: f32,
pub levels: u8,
pub lines: Option<Lines>,
}Expand description
How one style of a picture is made (the steps at the top of the module).
Fields§
§curve: f32Each brightness b (0 to 1) becomes b ^ curve first: 1 leaves it,
below 1 lightens the middle greys, above 1 darkens them.
stretch: f32The share of pixels stretched to black at the dark end, and to white at the light end (0.03 for 3%); 0 leaves the greys as they are.
levels: u8Each grey rounded to one of this many evenly spaced levels before the dither (black and white among them); 0 or 1 rounds nothing.
lines: Option<Lines>The art’s own dark lines drawn black on top, if any.
Implementations§
Trait Implementations§
impl Copy for Method
impl StructuralPartialEq for Method
Auto Trait Implementations§
impl Freeze for Method
impl RefUnwindSafe for Method
impl Send for Method
impl Sync for Method
impl Unpin for Method
impl UnsafeUnpin for Method
impl UnwindSafe for Method
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more