Cut down on drawPixmap and drawImage combinations

There are too many combinations and the data is not very useful when
it is impossible to get an overview. This cuts a few rare formats out
and reduces the sizes tested to one small for overhead benchmarking
and one large for bandwidth benchmarking.

Change-Id: If0fe33e0e02b8cba771094a79072036f2cd4cf48
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
This commit is contained in:
Allan Sandfeld Jensen 2018-04-12 13:27:20 +02:00
parent a88063008d
commit 2cc9776652

View File

@ -128,7 +128,7 @@ QPixmap rasterPixmap(const QImage &image)
QPlatformPixmap *data =
new QRasterPlatformPixmap(QPlatformPixmap::PixmapType);
data->fromImage(image, Qt::AutoColor);
data->fromImage(image, Qt::AutoColor | Qt::NoFormatConversion);
return QPixmap(data);
}
@ -614,9 +614,7 @@ void tst_QPainter::drawPixmapImage_data_helper(bool pixmaps)
QTest::addColumn<int>("type"); // 0 = circle, 1 = diag line, 2 = solid rect, 3 = alpharect
QList<QSize> sizes;
sizes << QSize(1, 1)
<< QSize(10, 10)
<< QSize(100, 100)
sizes << QSize(10, 10)
<< QSize(1000, 1000);
const char *typeNames[] = {
@ -658,7 +656,6 @@ void tst_QPainter::drawPixmapImage_data_helper(bool pixmaps)
QImage::Format_RGB32,
QImage::Format_ARGB32_Premultiplied,
QImage::Format_RGB16,
QImage::Format_ARGB8565_Premultiplied,
QImage::Format_BGR30,
QImage::Format_Invalid
};
@ -683,12 +680,9 @@ void tst_QPainter::drawPixmapImage_data_helper(bool pixmaps)
QImage::Format_ARGB32,
QImage::Format_ARGB32_Premultiplied,
QImage::Format_RGB16,
QImage::Format_ARGB8565_Premultiplied,
QImage::Format_RGB888,
QImage::Format_RGBX8888,
QImage::Format_RGBA8888,
QImage::Format_RGBA8888_Premultiplied,
QImage::Format_A2BGR30_Premultiplied,
QImage::Format_RGB30,
QImage::Format_Grayscale8,
QImage::Format_Invalid