mirror of
https://invent.kde.org/frameworks/kimageformats.git
synced 2026-02-24 16:22:57 -05:00
exr: write support and more
- Added support for writing EXR files - Large image support (tested with 32GiB 16-bit image) - OpenEXR multithreaded read/write support through the use of line blocks - Build option to enable conversion to sRGB when read (disabled by default) - Multi-view image reading support - Options support: Size, ImageFormat, Quality, CompressRatio - Metadata write/read support via EXR attributes The plugin is now quite complete. It should also work on KF5 (not tested): if there is the will to include this MR also on KF5, let me know and I will do all the necessary tests.
This commit is contained in:
committed by
Albert Astals Cid
parent
6a51407556
commit
7899c27a80
@ -42,6 +42,14 @@ public:
|
||||
void setTargetColorSpace(const QColorSpace &colorSpace);
|
||||
QColorSpace targetColorSpace() const;
|
||||
|
||||
/*!
|
||||
* \brief setDefaultSourceColorSpace
|
||||
* Set the source color space to use when the image does not have a color space.
|
||||
* \param colorSpace
|
||||
*/
|
||||
void setDefaultSourceColorSpace(const QColorSpace &colorSpace);
|
||||
QColorSpace defaultSourceColorSpace() const;
|
||||
|
||||
/*!
|
||||
* \brief convertedScanLine
|
||||
* Convert the scanline \a y.
|
||||
@ -62,14 +70,24 @@ public:
|
||||
* \note Only 24 bit or grater images.
|
||||
* \param image The source image.
|
||||
* \param targetColorSpace The target color space.
|
||||
* \param defaultColorSpace The default color space to use it image does not contains one.
|
||||
* \return True if the conversion should be done otherwise false.
|
||||
*/
|
||||
bool isColorSpaceConversionNeeded(const QImage &image, const QColorSpace &targetColorSpace) const;
|
||||
static bool isColorSpaceConversionNeeded(const QImage &image, const QColorSpace &targetColorSpace, const QColorSpace &defaultColorSpace = QColorSpace());
|
||||
|
||||
/*!
|
||||
* \brief isColorSpaceConversionNeeded
|
||||
*/
|
||||
inline bool isColorSpaceConversionNeeded(const QImage &image) const
|
||||
{
|
||||
return isColorSpaceConversionNeeded(image, _colorSpace, _defaultColorSpace);
|
||||
}
|
||||
|
||||
private:
|
||||
// data
|
||||
QImage::Format _targetFormat;
|
||||
QColorSpace _colorSpace;
|
||||
QColorSpace _defaultColorSpace;
|
||||
|
||||
// internal buffers
|
||||
QImage _tmpBuffer;
|
||||
|
||||
Reference in New Issue
Block a user