Trait dicom_encoding::adapters::PixelDataObject [−][src]
pub trait PixelDataObject {
fn rows(&self) -> Option<u16>;
fn cols(&self) -> Option<u16>;
fn samples_per_pixel(&self) -> Option<u16>;
fn bits_allocated(&self) -> Option<u16>;
fn number_of_frames(&self) -> Option<u16>;
fn number_of_fragments(&self) -> Option<u32>;
fn fragment(&self, fragment: usize) -> Option<Vec<u8>>;
fn raw_pixel_data(&self) -> Option<RawPixelData>;
}Expand description
PixelDataObject trait contains all relevant data to decode pixel data
Required methods
fn samples_per_pixel(&self) -> Option<u16>
fn samples_per_pixel(&self) -> Option<u16>
Return the SamplesPerPixel attribute or None if it is not found
fn bits_allocated(&self) -> Option<u16>
fn bits_allocated(&self) -> Option<u16>
Return the BitsAllocated attribute or None if it is not set
fn number_of_frames(&self) -> Option<u16>
fn number_of_frames(&self) -> Option<u16>
Return the NumberOfFrames attribute or None if it is not set
fn number_of_fragments(&self) -> Option<u32>
fn number_of_fragments(&self) -> Option<u32>
Returns the number of fragments or None for native pixel data
Return a specific encoded pixel fragment by index as Vec
fn raw_pixel_data(&self) -> Option<RawPixelData>
fn raw_pixel_data(&self) -> Option<RawPixelData>
Should return either a byte slice/vector if native pixel data or byte fragments if encapsulated. Returns None if no pixel data is found