3
0
Fork 0
mirror of https://github.com/JulianGro/overte.git synced 2025-04-18 03:36:22 +02:00

Let's actually use the result of our format conversion.

This commit is contained in:
Andrzej Kapolka 2014-03-20 14:27:38 -07:00
parent 0d432e169a
commit 56ff423cf5

View file

@ -313,7 +313,7 @@ void ImageReader::run() {
int imageArea = image.width() * image.height();
if (opaquePixels == imageArea) {
qDebug() << "Image with alpha channel is completely opaque:" << url;
image.convertToFormat(QImage::Format_RGB888);
image = image.convertToFormat(QImage::Format_RGB888);
}
QMetaObject::invokeMethod(texture.data(), "setImage", Q_ARG(const QImage&, image),
Q_ARG(bool, translucentPixels >= imageArea / 2));