pub trait Sample:
Copy
+ Default
+ Sealed
+ 'static {
// Required methods
fn data_type() -> DataType;
fn from_f64(value: f64) -> Self;
fn to_f64(self) -> f64;
fn read_vec(bytes: &[u8]) -> Result<Vec<Self>>;
fn into_pixel_data(values: Vec<Self>) -> PixelData;
fn append_le_bytes(self, out: &mut Vec<u8>);
}Required Methods§
fn data_type() -> DataType
fn from_f64(value: f64) -> Self
fn to_f64(self) -> f64
fn read_vec(bytes: &[u8]) -> Result<Vec<Self>>
fn into_pixel_data(values: Vec<Self>) -> PixelData
fn append_le_bytes(self, out: &mut Vec<u8>)
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.