pub struct PngMetadata {
pub width: u32,
pub height: u32,
pub bit_depth: u8,
pub color_type: u8,
pub has_alpha: bool,
}Expand description
Metadata read from a validated PNG without trusting filename extensions.
Fields§
§width: u32Pixel width.
height: u32Pixel height.
bit_depth: u8PNG bit depth.
color_type: u8PNG color-type number from the IHDR chunk.
has_alpha: boolWhether pixels can carry transparency through alpha or a tRNS chunk.
Trait Implementations§
Source§impl Clone for PngMetadata
impl Clone for PngMetadata
impl Copy for PngMetadata
Source§impl Debug for PngMetadata
impl Debug for PngMetadata
impl Eq for PngMetadata
Source§impl PartialEq for PngMetadata
impl PartialEq for PngMetadata
Source§impl Serialize for PngMetadata
impl Serialize for PngMetadata
impl StructuralPartialEq for PngMetadata
Auto Trait Implementations§
impl Freeze for PngMetadata
impl RefUnwindSafe for PngMetadata
impl Send for PngMetadata
impl Sync for PngMetadata
impl Unpin for PngMetadata
impl UnsafeUnpin for PngMetadata
impl UnwindSafe for PngMetadata
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