diff options
author | Qt Continuous Integration System <qt-info@nokia.com> | 2010-09-30 05:56:19 (GMT) |
---|---|---|
committer | Qt Continuous Integration System <qt-info@nokia.com> | 2010-09-30 05:56:19 (GMT) |
commit | 3fe98c88473712e1c486f4b93f2ac41b7b07331b (patch) | |
tree | 986ae00ba9b286ac412f56c9707a948e3815a54e /src/gui/painting/qpaintengine_raster.cpp | |
parent | d6eb899ee2c937a871dd945a995e2fd4a3eb7821 (diff) | |
parent | 02aecce59cb76ceb88f63520355381c3b5c5a513 (diff) | |
download | Qt-3fe98c88473712e1c486f4b93f2ac41b7b07331b.zip Qt-3fe98c88473712e1c486f4b93f2ac41b7b07331b.tar.gz Qt-3fe98c88473712e1c486f4b93f2ac41b7b07331b.tar.bz2 |
Merge branch '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-2 into 4.7-integration
* '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-2:
QTextCodec: Fix valgrind warning when using QTextCodec in destructions functions
Fix double painting when adding an item into a linear layout
Fixed antialiased rasterization bug in raster engine.
Fixed potential crash when loading corrupt GIFs.
Work around an ATI driver problem with mutli-sampled pbuffers.
tst_qstatemachine.cpp: fix compilation with Sun Studio
Fixed regression in clipping.qps autotest on 64-bit.
Fixed crash when using Qt::WA_DeleteOnClose on a QPrintDialog on Mac.
Fixed performance regression in curve stroking.
Don't disable texture_from_pixmap on GLX/X11 by default.
Avoid creating copy of an image in memory when storing as png
Doc update for the support of MSVC 2010 64-bit
fix documentation of drawText(int, int, int, int, ...
Optimization of pixel conversion when storing jpeg
Don't pretend to support single buffered EGL surfaces.
Named anonymous struct in the OpenGL paint engine.
Fixes gray_raster incorrectly reporting out of memory error.
Diffstat (limited to 'src/gui/painting/qpaintengine_raster.cpp')
-rw-r--r-- | src/gui/painting/qpaintengine_raster.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/gui/painting/qpaintengine_raster.cpp b/src/gui/painting/qpaintengine_raster.cpp index 09a87aa..36e1082 100644 --- a/src/gui/painting/qpaintengine_raster.cpp +++ b/src/gui/painting/qpaintengine_raster.cpp @@ -4148,6 +4148,10 @@ void QRasterPaintEnginePrivate::rasterize(QT_FT_Outline *outline, rasterize(outline, callback, (void *)spanData, rasterBuffer); } +extern "C" { + int q_gray_rendered_spans(QT_FT_Raster raster); +} + void QRasterPaintEnginePrivate::rasterize(QT_FT_Outline *outline, ProcessSpans callback, void *userData, QRasterBuffer *) @@ -4212,10 +4216,13 @@ void QRasterPaintEnginePrivate::rasterize(QT_FT_Outline *outline, bool done = false; int error; + int rendered_spans = 0; + while (!done) { rasterParams.flags |= (QT_FT_RASTER_FLAG_AA | QT_FT_RASTER_FLAG_DIRECT); rasterParams.gray_spans = callback; + rasterParams.skip_spans = rendered_spans; error = qt_ft_grays_raster.raster_render(*grayRaster.data(), &rasterParams); // Out of memory, reallocate some more and try again... @@ -4244,6 +4251,8 @@ void QRasterPaintEnginePrivate::rasterize(QT_FT_Outline *outline, #endif Q_CHECK_PTR(rasterPoolBase); // note: we just freed the old rasterPoolBase. I hope it's not fatal. + rendered_spans += q_gray_rendered_spans(*grayRaster.data()); + qt_ft_grays_raster.raster_done(*grayRaster.data()); qt_ft_grays_raster.raster_new(grayRaster.data()); qt_ft_grays_raster.raster_reset(*grayRaster.data(), rasterPoolBase, rasterPoolSize); |