mirror of
https://invent.kde.org/frameworks/kimageformats.git
synced 2026-07-14 06:11:35 -04:00
JXL improvements
Highlights of the patch: - Supersede MR !249 - Added FP16 and FP32 images support thus preserving HDR values (read / write, required libjxl 0.9+). - Added Gray8 and Gray16 support (read / write). - Indexed images are saved as Gray8 when palette is gray scale. - Binary images are saved as Gray8 (does JXL natively support binary images?). - Simplified writing process by partially removing the use of additional buffers. - Added XMP metadata support by decoding/encoding Boxes. - Changed maximum image size in pixels in accordance with JXL feature level 5 (still limited to 256 megapixels). Compatibility: - Older versions of this plugin load FP images correctly as UINT16 (obviously losing HDR info). - HDR images saved with this patch are also loaded correctly by Gimp and Photoshop. - Grayscale images saved with this patch are also loaded correctly by Gimp and Photoshop. Compilation modifiers for cmake file: - `JXL_HDR_PRESERVATION_DISABLED`: disable the FP support (behaves like previous versions). - `JXL_DECODE_BOXES_DISABLED`: disable metadata reading (behaves like previous versions).
This commit is contained in:
@@ -51,6 +51,7 @@ private:
|
||||
bool countALLFrames();
|
||||
bool decode_one_frame();
|
||||
bool rewind();
|
||||
bool decodeBoxes();
|
||||
|
||||
enum ParseJpegXLState {
|
||||
ParseJpegXLError = -1,
|
||||
@@ -77,6 +78,7 @@ private:
|
||||
|
||||
QImage m_current_image;
|
||||
QColorSpace m_colorspace;
|
||||
QByteArray m_xmp;
|
||||
|
||||
QImage::Format m_input_image_format;
|
||||
QImage::Format m_target_image_format;
|
||||
|
||||
Reference in New Issue
Block a user