Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
|
Public Member Functions | |
Jpeg2000JasperReader (QIODevice *iod, const SubFormat format=Jp2Format) | |
~Jpeg2000JasperReader () | |
bool | read (QImage *pImage) |
bool | write (const QImage &image, int quality) |
Opens the file data and attempts to decode it using the Jasper library. | |
Definition at line 42 of file qjp2handler.cpp.
Construct a Jpeg2000JasperReader using the provided imageIO. Note that currently the jasper library is initialized in this constructor, (and freed in the destructor) which means that:
Definition at line 298 of file qjp2handler.cpp.
References QImageReader::allocationLimit(), and qDebug.
Jpeg2000JasperReader::~Jpeg2000JasperReader | ( | ) |
Definition at line 327 of file qjp2handler.cpp.
References qDebug.
bool Jpeg2000JasperReader::read | ( | QImage * | pImage | ) |
Opens the file data and attempts to decode it using the Jasper library. Returns true if successful, false on failure
Definition at line 348 of file qjp2handler.cpp.
References QImageIOHandler::allocateImage(), QImage::Format_ARGB32, QImage::Format_Grayscale8, QImage::Format_Invalid, QImage::Format_RGB32, imageData, qDebug, and QIODevice::readAll().
bool Jpeg2000JasperReader::write | ( | const QImage & | image, |
int | quality ) |
Opens the file data and attempts to decode it using the Jasper library.
Returns true on success, false on failure.
32-bit and color mapped color images are encoded as RGB images, color mapped grayscale images are encoded as grayscale images
Definition at line 757 of file qjp2handler.cpp.
References QImage::allGray(), QString::arg(), QImage::depth(), QImage::hasAlphaChannel(), QImage::height(), Jp2Format, qDebug, qstrdup(), str, QImage::width(), and QIODevice::write().