[−][src]Struct nanachi::buffer::GenericBuffer
2D image buffer for manipulation.
Implementations
impl<P: Pixel> GenericBuffer<P>
[src]
pub fn from_pixel(width: u32, height: u32, pixel: P) -> Self
[src]
impl GenericBuffer<f64>
[src]
pub fn new(width: u32, height: u32) -> Self
[src]
pub fn rasterize(
&mut self,
segments: impl Iterator<Item = (Point, Point)>,
fill_rule: impl FillRule,
writer: &mut impl FnMut(u32, u32, f64),
write_transparent_src: bool
)
[src]
&mut self,
segments: impl Iterator<Item = (Point, Point)>,
fill_rule: impl FillRule,
writer: &mut impl FnMut(u32, u32, f64),
write_transparent_src: bool
)
Write the area of the [Path
].
pub fn rasterize_no_aa(
&mut self,
segments: impl Iterator<Item = (Point, Point)>,
fill_rule: impl FillRule,
writer: &mut impl FnMut(u32, u32, f64),
write_transparent_src: bool
)
[src]
&mut self,
segments: impl Iterator<Item = (Point, Point)>,
fill_rule: impl FillRule,
writer: &mut impl FnMut(u32, u32, f64),
write_transparent_src: bool
)
Write the area of the [Path
] without anti-aliasing.
pub fn transfer(
&mut self,
fill_rule: impl FillRule,
writer: &mut impl FnMut(u32, u32, f64),
write_transparent_src: bool,
bound: [f64; 4]
)
[src]
&mut self,
fill_rule: impl FillRule,
writer: &mut impl FnMut(u32, u32, f64),
write_transparent_src: bool,
bound: [f64; 4]
)
Trait Implementations
impl<P: Pixel> Buffer<P> for GenericBuffer<P>
[src]
pub fn dimensions(&self) -> (u32, u32)
[src]
pub fn get_pixel(&self, x: u32, y: u32) -> &P
[src]
pub fn get_pixel_mut(&mut self, x: u32, y: u32) -> &mut P
[src]
pub fn put_pixel(&mut self, x: u32, y: u32, pixel: P)
[src]
impl<P: Clone + Pixel> Clone for GenericBuffer<P>
[src]
pub fn clone(&self) -> GenericBuffer<P>
[src]
pub fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl<'_> Into<ImageBuffer<Rgba<u8>, Vec<u8>>> for &'_ GenericBuffer<Rgba>
[src]
impl<'_> Into<ImageBuffer<Rgba<u8>, Vec<u8>>> for &'_ GenericBuffer<PremultipliedRgba>
[src]
Auto Trait Implementations
impl<P> RefUnwindSafe for GenericBuffer<P> where
P: RefUnwindSafe,
P: RefUnwindSafe,
impl<P> Send for GenericBuffer<P> where
P: Send,
P: Send,
impl<P> Sync for GenericBuffer<P> where
P: Sync,
P: Sync,
impl<P> Unpin for GenericBuffer<P> where
P: Unpin,
P: Unpin,
impl<P> UnwindSafe for GenericBuffer<P> where
P: UnwindSafe,
P: UnwindSafe,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> SetParameter for T
pub fn set<T>(&mut self, value: T) -> <T as Parameter<Self>>::Result where
T: Parameter<Self>,
T: Parameter<Self>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,