pub struct DctScanlineDecoder { /* private fields */ }Expand description
Scanline decoder for DCTDecode (JPEG) data.
Decodes the full JPEG internally on construction, then yields one scanline at a time based on the decoded pixel stride.
Implementations§
Source§impl DctScanlineDecoder
impl DctScanlineDecoder
Trait Implementations§
Source§impl ScanlineDecoder for DctScanlineDecoder
impl ScanlineDecoder for DctScanlineDecoder
Source§fn count_comps(&self) -> u8
fn count_comps(&self) -> u8
Number of color components per pixel (e.g. 1 for gray, 3 for RGB, 4
for CMYK). Mirrors PDFium’s
CountComps().Source§fn row_stride(&self) -> usize
fn row_stride(&self) -> usize
Number of bytes per row:
(width * count_comps * bpc + 7) / 8.Source§fn decode_scanline(&mut self) -> Result<Option<&[u8]>, DecodeError>
fn decode_scanline(&mut self) -> Result<Option<&[u8]>, DecodeError>
Decode and return the next scanline. Read more
Source§fn current_line(&self) -> Option<usize>
fn current_line(&self) -> Option<usize>
Current line index (0-based), or
None if no lines have been read yet.Auto Trait Implementations§
impl Freeze for DctScanlineDecoder
impl RefUnwindSafe for DctScanlineDecoder
impl Send for DctScanlineDecoder
impl Sync for DctScanlineDecoder
impl Unpin for DctScanlineDecoder
impl UnsafeUnpin for DctScanlineDecoder
impl UnwindSafe for DctScanlineDecoder
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more