pub fn open(path: &str) -> Self {
        let path = Path::new(path);
        let file = File::open(path).unwrap();

        let decoder = png::Decoder::new(file);
        let (info, reader) = decoder.read_info().unwrap();

        Self { info, reader }
    }
/// Opens a PNG file without loading data yet
Opens a PNG file without loading data yet
Opens a PNG file without loading data yet
pub fn open(path: &str) -> Self {
        let path = Path::new(path);
        let file = File::open(path).unwrap();
        let decoder = png::Decoder::new(file);
        let (info, reader) = decoder.read_info().unwrap();
        Self { info, reader }
    }
pub fn open ( path : & str ) -> Self { let path = Path :: new ( path ) ; let file = File :: open ( path ) . unwrap ( ) ; let decoder = png :: Decoder :: new ( file ) ; let ( info , reader ) = decoder . read_info ( ) . unwrap ( ) ; Self { info , reader } }
Opens a PNG file without loading data yet
Opens a PNG file without loading data yet
path
&str
path
&str