Function qoi::encode::encode_to_buf
source ยท pub fn encode_to_buf(
buf: impl AsMut<[u8]>,
data: impl AsRef<[u8]>,
width: u32,
height: u32,
) -> Result<usize>
Expand description
Encode the image into a pre-allocated buffer.
Returns the total number of bytes written.