pub fn bitmap( bitmap: &Bitmap, format: EncodedImageFormat, quality: impl Into<Option<u32>>, ) -> Option<Vec<u8>>