pub trait ImageLinePattern {
// Required methods
fn pattern_width(&self) -> i32;
fn line_width(&self) -> i32;
fn width(&self) -> f64;
fn pixel(&self, p: &mut Rgba8, x: i32, y: i32);
}Expand description
Trait for image-line patterns (both standard and pow2-optimized).
This abstracts over LineImagePattern and LineImagePatternPow2 so that
RendererOutlineImage can work with either type.
Required Methods§
Sourcefn pattern_width(&self) -> i32
fn pattern_width(&self) -> i32
Pattern width in subpixel coordinates (for repeating).
Sourcefn line_width(&self) -> i32
fn line_width(&self) -> i32
Line width in subpixel coordinates (half-height of pattern).