Add support for IEEEFP RGB/RGBA/CMYK(32) decoding

This commit is contained in:
Andrew Champion committed 2020-02-10 13:21:13 +00:00
1 parent bbc49291e4
commit 97c888f166
6 files changed
+29 -2

No files matched your search

+6
View File
@@ -672,6 +672,12 @@ impl<R: Read + Seek> Decoder<R> {
reader.read_u32_into(&mut buffer[..bytes / 4])?;
bytes / 4
}
(ColorType::RGBA(32), DecodingBuffer::F32(ref mut buffer))
| (ColorType::RGB(32), DecodingBuffer::F32(ref mut buffer))
| (ColorType::CMYK(32), DecodingBuffer::F32(ref mut buffer)) => {
reader.read_f32_into(&mut buffer[..bytes / 4])?;
bytes / 4
}
(ColorType::RGBA(64), DecodingBuffer::U64(ref mut buffer))
| (ColorType::RGB(64), DecodingBuffer::U64(ref mut buffer))
| (ColorType::CMYK(64), DecodingBuffer::U64(ref mut buffer)) => {