trait Sample {
type Representation;
// Required methods
fn from_bytes(
bytes: &[u8],
row_size: usize,
output_buf: &mut [u8],
) -> ImageResult<()>;
fn from_ascii(
reader: &mut dyn Read,
output_buf: &mut [u8],
) -> ImageResult<()>;
// Provided methods
fn sample_size() -> u32 { ... }
fn bytelen(width: u32, height: u32, samples: u32) -> ImageResult<usize> { ... }
}
Required Associated Types§
type Representation
Required Methods§
fn from_bytes( bytes: &[u8], row_size: usize, output_buf: &mut [u8], ) -> ImageResult<()>
fn from_ascii(reader: &mut dyn Read, output_buf: &mut [u8]) -> ImageResult<()>
Provided Methods§
sourcefn sample_size() -> u32
fn sample_size() -> u32
Representation size in bytes
fn bytelen(width: u32, height: u32, samples: u32) -> ImageResult<usize>
Object Safety§
This trait is not object safe.