fixed bug in quality of html-embedded images

This commit is contained in:
csoler 2023-01-16 22:23:58 +01:00
parent 7aacfb9aef
commit e60ee730b4

View File

@ -188,7 +188,7 @@ int ImageUtil::checkSize(QByteArray &bytearray, const QImage &img,const char *fo
//std::cout << QString("Trying image: format PNG, size %1x%2, colors %3\n").arg(img.width()).arg(img.height()).arg(img.colorCount()).toStdString();
if (buffer.open(QIODevice::WriteOnly)) {
if (img.save(&buffer, format, 0)) {
if (img.save(&buffer, format, 85)) {
size = bytearray.length();
} else {
std::cerr << "ImageUtil: image can't be saved to buffer" << std::endl;