summaryrefslogtreecommitdiffstats
path: root/src/gui/painting/qblendfunctions.cpp
diff options
context:
space:
mode:
authorMichael Brasser <michael.brasser@nokia.com>2009-05-29 08:18:29 +1000
committerMichael Brasser <michael.brasser@nokia.com>2009-05-29 08:18:29 +1000
commit24e904b2ef438bafb24456f934ea93497f43f5c1 (patch)
treeff0d6918591b7ef96e0951dcdc70b34e9ec84b2f /src/gui/painting/qblendfunctions.cpp
parent866813b6779a27e974c30d1023a5d734fa0318c9 (diff)
Further optimized fast scaling of ARGB8565 images onto RGB16 images.
This improves performance on embedded. Reviewed-by: Samuel
Diffstat (limited to 'src/gui/painting/qblendfunctions.cpp')
-rw-r--r--src/gui/painting/qblendfunctions.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/gui/painting/qblendfunctions.cpp b/src/gui/painting/qblendfunctions.cpp
index f83ff7b9be..4bdaf0b44e 100644
--- a/src/gui/painting/qblendfunctions.cpp
+++ b/src/gui/painting/qblendfunctions.cpp
@@ -105,10 +105,10 @@ struct Blend_RGB16_on_RGB16_ConstAlpha {
};
struct Blend_ARGB24_on_RGB16_SourceAlpha {
- inline void write(quint16 *dst, qargb8565 src) {
+ inline void write(quint16 *dst, const qargb8565 &src) {
const uint alpha = src.alpha();
if (alpha) {
- quint16 s = qrgb565(src).rawValue();
+ quint16 s = src.rawValue16();
if (alpha < 255)
s += BYTE_MUL_RGB16(*dst, 255 - alpha);
*dst = s;
@@ -125,7 +125,7 @@ struct Blend_ARGB24_on_RGB16_SourceAndConstAlpha {
src = src.byte_mul(src.alpha(m_alpha));
const uint alpha = src.alpha();
if (alpha) {
- quint16 s = qrgb565(src).rawValue();
+ quint16 s = src.rawValue16();
if (alpha < 255)
s += BYTE_MUL_RGB16(*dst, 255 - alpha);
*dst = s;