[−][src]Trait ffimage::core::traits::Pixel
Generic pixel container
Associated Types
type T: StorageType
Type of the container elements
Required methods
fn at(&self, index: usize) -> Self::T
Returns the channel value at the specified index
fn cast_from_slice(raw: &[Self::T]) -> Option<&Self>
Transmute the slice into a pixel reference
fn cast_from_slice_mut(raw: &mut [Self::T]) -> Option<&mut Self>
Transmute the slice into a writable pixel reference
fn try_from(raw: &[Self::T]) -> Result<Self, TryFromSliceError>
Convert a memory region into a pixel by copying the bytes
fn channels() -> u8
Number of channels for this pixel
fn subpixels() -> u8
Number of image pixels for this pixel