summaryrefslogtreecommitdiffstats
path: root/src/gui/painting
Commit message (Collapse)AuthorAgeFilesLines
* Update license headers to release version.Jason McDonald2010-10-18169-2197/+2197
|
* Fixed performance regression in curve stroking.Samuel Rødal2010-10-043-6/+8
| | | | | | | | | | | | | | | | Change c46688b8a88da made us use m_curve_threshold for both QBezier::shifted and QBezier::toPolygon, and adjusted the threshold dynamically based on the painter scale. Since the threshold in shifted was already relative to the pen width, it is independent from the painter scale. Instead, we need to set a separate threshold for dashing. Also, in several places we were calling setCurveThresholdForTransform with the painter matrix even though we were transforming the points into device coordinate space before stroking. Task-number: QTBUG-13894 Reviewed-by: Gunnar Sletta (cherry picked from commit d60dc7cba21794866c9382f83080fab1a129eb08)
* Fixed floating point overflow issues in QRasterizer::rasterizeLineSamuel Rødal2010-09-291-60/+79
| | | | | | | | | | | | | | | | | | Change 7c673a4cf64ba04 introduced some autotest failures in the fpe_steepSlopes test in QPainter. Since the other rasterizers all deal in a 26.6 fixed point coordinate space we should snap the line vertices to this to prevent floating point overflows due to very steep slopes. This also necessitates keeping track of four different slope / inverse slope increments for each of the four edges. This also fixes a previously QEXPECT_FAIL'ed test case. Task-number: QTBUG-13429 Reviewed-by: Trond (cherry picked from commit 93199a5b7082fd484b7f21ad4825d71693ecead2)
* Fixed scaled point drawing with square cap in raster paint engine.Samuel Rødal2010-09-291-24/+17
| | | | | | | | | | | | With a large pen width and a small scale, due to the hacky way we draw points (stroking a line from (x, y) to (x + tiny_amount, y)), we some times end up snapping these two points to the same in rasterizeLine(). If we instead apply the SquareCap before we do clipping / snapping we don't get this problem. Task-number: QTBUG-13429 Reviewed-by: Trond (cherry picked from commit 7c673a4cf64ba043bb27f90287517bdcdd7a21db)
* Fixed drawing a large number of glyphs with the same font under GL.Trond Kjernåsen2010-09-232-8/+18
| | | | | | | | | | | | | | | Our glyph caching system doesn't take GL texture size limitation into account, and assumes you can create an infinitely large texture. On top of that, the cache will never create a cache that is wider than 256, or QT_DEFAULT_TEXTURE_GLYPH_CACHE_WIDTH, which means we'll hit the texture size limit even faster. With this patch the entire texture is utilized. However, to fix in properly we need to support having multiple texture for each font engine. That will be fixed shortly (see task QTBUG-13784). Task-number: QT-3971 Reviewed-by: Eskil (cherry picked from commit eb2926a2f9607e985b8bca54346e6fdf91343247)
* Merge branch '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-1 into ↵Qt Continuous Integration System2010-09-172-3/+3
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 4.7-integration * '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-1: (45 commits) Doc: css fine tuning Doc: Fixed a non-compiling example. Doc: removing linebreak Doc: correcting html template Doc: Updated What's new in 4.7 page Doc: Updated What's new in 4.7 page Doc: Removing google analytics from offline docs Doc: fixing creator bug in page footer Doc: correcting html template - validating Doc: fixing issues with table indent - css Doc: Fixing style: line height, ol indent, coulmns (css3) Doc: correcting html template Doc: Updated the Mac requirements page. Doc: Cleaning up the known issues page. Pointing people to check the online resources. Added a QFormLayout snippet to the layout.qdoc and layouts.cpp Doc: Removing section about Multimedia - playback and declarative elements. This was descoped from Qt 4.7. Doc: Listed undoable operations in QTextDocument Revert "Doc: fixing page name bug caused by 07bbace404078dcfd82eff717daa97299b8ba52c changing qml elements page" Doc: Note on updating proxy models with dynamic sort filters qdoc: Fixed an html formatting error in the QML property list. ...
| * Merge branch '4.7-upstream' into 4.7-docA-Team2010-09-161-8/+7
| |\
| * \ git Merge branch '4.7-upstream' into 4.7-docJesper Thomschutz2010-09-153-4/+7
| |\ \ | | | | | | | | | | | | | | | | Conflicts: src/gui/kernel/qgesturemanager.cpp
| * \ \ Merge branch '4.7-upstream' into 4.7-docA-Team2010-09-132-76/+7
| |\ \ \
| * \ \ \ Merge branch '4.7-upstream' into 4.7-docA-Team2010-09-111-2/+4
| |\ \ \ \
| * \ \ \ \ Merge branch '4.7-upstream' into 4.7-docA-Team2010-09-101-0/+1
| |\ \ \ \ \
| * \ \ \ \ \ Merge branch '4.7-upstream' into 4.7-docA-Team2010-09-092-18/+122
| |\ \ \ \ \ \
| * \ \ \ \ \ \ Merge branch '4.7-oslo1' into 4.7-docA-Team2010-09-074-291/+240
| |\ \ \ \ \ \ \
| * \ \ \ \ \ \ \ Merge commit 'staging-1/4.7' into doc-4.7Morten Engvoldsen2010-09-038-155/+370
| |\ \ \ \ \ \ \ \
| * \ \ \ \ \ \ \ \ Merge branch '4.7' of git@scm.dev.nokia.troll.no:qt/qt-doc-team into doc-4.7Morten Engvoldsen2010-09-022-3/+3
| |\ \ \ \ \ \ \ \ \
| | * | | | | | | | | Fixed spelling, broken links, and missing default values.Jerome Pasion2010-08-302-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Tasks: QTBUG-13271, QTBUG-13212, QTBUG-12321 Reviewer: David Boddie
* | | | | | | | | | | Fixed compilation of qdrawhelper.cpp with XLC 10Rohan McGovern2010-09-161-1/+1
| |_|_|_|_|_|_|_|_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | With XLC 10, calls to static functions within a template function need to be fully qualified. Reviewed-by: Marius Storm-Olsen
* | | | | | | | | | Merge branch '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-2 into 4.7David Boddie2010-09-158-100/+141
|\ \ \ \ \ \ \ \ \ \ | | |_|_|_|_|_|_|_|/ | |/| | | | | | | |
| * | | | | | | | | Merge branch '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-2 into ↵Qt Continuous Integration System2010-09-141-1/+1
| |\ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 4.7-integration * '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-2: Fix top-left corner of rounded rects in QPaintEngineEx
| | * | | | | | | | | Fix top-left corner of rounded rects in QPaintEngineExGunnar Sletta2010-09-141-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Reviewed-by: Rhys Weatherley
| * | | | | | | | | | Merge branch '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-1 into ↵Qt Continuous Integration System2010-09-141-1/+1
| |\ \ \ \ \ \ \ \ \ \ | | |/ / / / / / / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 4.7-integration * '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-1: (25 commits) run depend_command even if the binary has no absolute path fix scaleFactor/totalScaleFactor in QPinchGestureRecognizer Added velocity property to the QPanGesture. Changed the speed property on QSwipeGesture to velocity fix typos in comment unbreak test Don't add generic subdirs project twice. Remove debug, quiet warnings. Fix memory leaks and valgrind errors. QStroker: Fix erroneous SvgMiterJoin behavior for parallel lines Revert "Properly implement qobject_cast for const pointers." Bearer management: Fix compilation with namespace. fetch next token after class definition opening delay next token fetching when opening namespace don't let operator overloads confuse us don't try to show source when no locations are given Implement a private API for setting title widgets Fix the bug for QSettings on Windows, to store qint32/quint32, qint64/quint64 in Windows registry. fix CRLF Added private API to install an x11EventFilter ...
| | * | | | | | | | | Merge branch '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-1 into ↵Qt Continuous Integration System2010-09-131-1/+1
| | |\ \ \ \ \ \ \ \ \ | | | |_|_|_|_|_|_|_|/ | | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 4.7-integration * '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-1: (25 commits) run depend_command even if the binary has no absolute path fix scaleFactor/totalScaleFactor in QPinchGestureRecognizer Added velocity property to the QPanGesture. Changed the speed property on QSwipeGesture to velocity fix typos in comment unbreak test Don't add generic subdirs project twice. Remove debug, quiet warnings. Fix memory leaks and valgrind errors. QStroker: Fix erroneous SvgMiterJoin behavior for parallel lines Revert "Properly implement qobject_cast for const pointers." Bearer management: Fix compilation with namespace. fetch next token after class definition opening delay next token fetching when opening namespace don't let operator overloads confuse us don't try to show source when no locations are given Implement a private API for setting title widgets Fix the bug for QSettings on Windows, to store qint32/quint32, qint64/quint64 in Windows registry. fix CRLF Added private API to install an x11EventFilter ...
| | | * | | | | | | | QStroker: Fix erroneous SvgMiterJoin behavior for parallel linesAndreas Kling2010-09-121-1/+1
| | | | |_|_|_|_|_|/ | | | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QLineF::intersect() yields an undefined intersectionPoint for parallel lines. Thus if the distance to 0,0 is shorter than the current miter limit, we would draw a triangle to 0,0. Handle this by not drawing the triangle for parallel lines. This matches the behavior of Qt::MiterJoin.
| * | | | | | | | | Use aligned operations for solid SourceOver operations.Benjamin Poulain2010-09-131-2/+5
| |/ / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Aligned load() and store() have been shown to be faster for the composition functions. This patch applies this to the solid SourceOver function. Reviewed-by: Samuel Rødal
| * | | | | | | | Use the stream operation for the SSE2 implementation of memfill32Benjamin Poulain2010-09-131-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Writing the data of memfill() to a cacheline is unecessary because the data is not reused directly. We can use the stream operations to avoid the cache completely. When testing memfill32 separately, the function is twice as fast on Core2 and Atom. Reviewed-by: Samuel Rødal
| * | | | | | | | Remove the memory safety for the first scanline of the SSSE3 blendingBenjamin Poulain2010-09-131-72/+3
| |/ / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Memory is allocated on 16 bytes boundaries. We can do the aligned load without risking a invalid memory access. This simplify the code. Reviewed-by: Samuel Rødal
| * | | | | | | Merge branch '4.7' of scm.dev.nokia.troll.no:qt/qt-s60-public into ↵Qt Continuous Integration System2010-09-101-2/+4
| |\ \ \ \ \ \ \ | | |_|_|_|_|_|/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 4.7-integration * '4.7' of scm.dev.nokia.troll.no:qt/qt-s60-public: Fix crash in QRuntimeGraphicsSystem due to destruction order. Fix crash in OpenVG when failing to allocate large VGImages. Updated 4.7.0 changelog
| | * | | | | | Fix crash in QRuntimeGraphicsSystem due to destruction order.Jason Barron2010-09-101-2/+4
| | | |_|_|_|/ | | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Firstly, fix a "leak" by deleting the graphics system when QApplication is destroyed. Secondly, fix a crash when the following scenario occurs: - ~QApplication() deletes the current graphics system (see above) - ~QApplication() calls qt_cleanup() - qt_cleanup() calls QPixmapCache::clear() to delete pixmaps - ~QRuntimePixmapData() tries to remove the pixmap from the runtime graphics system, but it has already been deleted. - *Crash* Reviewed-by: Gunnar Sletta Reviewed-by: Jani Hautakangas
| * | | | | | Fixed compilation and API of meego graphics system.Samuel Rødal2010-09-101-0/+1
| |/ / / / /
| * | | | | Removing Q_ENUMS declaration in QTransformJørgen Lind2010-09-091-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | since QTransform does not inherit QObject its redundant Reviewed-by: gunnar
| * | | | | qdrawhelper: Optimisations in fetchTransformedBilinearOlivier Goffart2010-09-081-30/+59
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Scaling down, no rotation, with SSE2. Specialize for ARGB32 not tiled, so the pixelbound can be simplified Reviewed-by: Samuel
| * | | | | qdrawhelper: use SSE2 for interpolation in fetchTransformedBilinearOlivier Goffart2010-09-081-0/+77
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | when scale down, with no rotations Process the pixel 4 by 4 and do the interpolation using SSE2 Reviewed-by: Samuel
| * | | | | qdrawhelper: small optimisations in fetchTransformBilinearOlivier Goffart2010-09-081-16/+15
| | |_|_|/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Another way to compute the interpolation that does less multiplications. Small inpact on benchmark Made-with: Samuel
* | | | | Doc: Continued work on the QML documentation.David Boddie2010-09-141-8/+7
|/ / / /
* | | | Allow Windows x64 to use SSE2 to speed up blendingliang jian2010-09-064-105/+229
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Windows 64 does not support MMX with MSVC. This is a problem with the way SSE is currently used because it rely on previous vector instructions being available. This patches fixes that by using the intended functions for SSE2 on Windows. Merge-request: 792 Reviewed-by: Benjamin Poulain <benjamin.poulain@nokia.com>
* | | | qdrawhelper: micro optimisation in fetchTransformBilinearOlivier Goffart2010-09-031-7/+7
| | | | | | | | | | | | | | | | | | | | | | | | move the -1 out of the loop Reviewed-by: Benjamin Poulain
* | | | qdrawhelper: Remove blend_transformed_bilinear_argbOlivier Goffart2010-09-021-179/+4
| |_|/ |/| | | | | | | | | | | | | | | | | With the recent optimisation in fetchTransformedBilinear, the generic path is faster than the 'optimized' path Reviewed-by: Samuel
* | | Fix a crash when passing a null pixmap to QPainter::drawPixmapFragments().Trond Kjernåsen2010-09-011-1/+1
| | | | | | | | | | | | | | | Task-number: QTBUG-13331 Reviewed-by: Samuel
* | | Use NEON and preloading for 16 bit small / medium sized image blits.Samuel Rødal2010-09-014-4/+108
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This gives a nice speedup for blitting of small and medium sized images by using preloading and avoiding function call overhead to memcpy for each scanline. For larger image widths memcpy becomes more efficient. Speedups of up to 40 % for 64 pixel wide images were measured. For image widths between 2 and 16 the speedup ranges between 12 % and 28 %. Task-number: QT-3401 Reviewed-by: Benjamin Poulain <benjamin.poulain@nokia.com>
* | | Undefined SSE symbols when crosscompiling Qt on PPC.Benjamin Poulain2010-08-314-11/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Qt does not build on PowerPC when compiling for both x86 and PPC on Mac. The compiler is invoked only once for both architecture so the defines are there in order to get the optimized path for x86. Those defines needs to be removed from the compilation environment when the target is set to PPC by GCC. Reviewed-by: Kent Hansen
* | | Fix QStaticText with OpenGL1 engineEskil Abrahamsen Blomfeldt2010-08-301-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | Like OpenGL2 and OpenVG, the OpenGL1 paint engine also transforms text coordinates itself and does not require QStaticText to use device coordinates. Task-number: QTBUG-13228 Reviewed-by: Samuel
* | | qdrawhelper: backport the optimisations in fetchTransformBilinear from ↵Olivier Goffart2010-08-301-138/+257
|/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | master to 4.7 This backport the following commits: e55b6a3 qdrawhelper: remove code duplication 0d7e683 qdrawhelper: optimize fetchTransformedBilinear 29ef46e Fix compilation with RVCT 6601458 qdrawhelper: Use SSE2 in fetchTransformedBilinear (when scalling up) 398ef0ca Fix nasty copy-paste bug in fetchTransformedBilinear() d585ece qdrawhelper: fix assert in fetchTransformedBilinear Reviewed-by: Benjamin Poulain
* | Apparently QPen::brush() can't return a NoBrush for a NoPen.Trond Kjernåsen2010-08-272-6/+4
| | | | | | | | | | | | | | | | There are explicit tests in qdatastream for this. IMO it's wrong, wrong, wrong, but it's currently abused in the SVG module so we can't change it. Reviewed-by: Gunnar
* | Calling QPen::brush() on a Qt::NoPen pen, should return QBrush::NoBrush.Trond Kjernåsen2010-08-261-0/+2
| | | | | | | | | | | | | | | | | | This could cause some strange things to happen in our fallback code used for e.g. printing, since the brush might be valid and e.g. contain alpha values etc. Task-number: QTBUG-12263 Reviewed-by: Gunnar
* | Revert "Refactor blend_transformed_bilinear to simplify the blend type checking"Olivier Goffart2010-08-261-67/+66
| | | | | | | | | | | | | | | | | | This reverts commit d2089600ea247b5d6354e8eee4becf40802c4693. Reverting in order to avoid conflict in the master branch. We are going to consider backporting the changes to Qt 4.7.1 Reviewed-by: Benjamin Poulain
* | Refactor blend_transformed_bilinear to simplify the blend type checkingBenjamin Poulain2010-08-251-66/+67
| | | | | | | | | | | | | | | | | | | | | | The function blend_transformed_bilinear_argb() was checking the blend type at runtime for each pixel in order to clamp the coordinates. This code was duplicated in both branch of the function. This patch factorize the code by doing the clamping in a template function. Reviewed-by: Samuel Rødal
* | Implement qt_memfill32 with Neon.Benjamin Poulain2010-08-253-0/+40
| | | | | | | | | | | | | | | | | | | | | | This patch introduce a implementation of qt_memfill32 with the Neon instructions set from ARMv7. The loop is unrolled 1 time to get better performance. This implementation of memfill is 330% faster on the N900. Reviewed-by: Samuel Rødal
* | Implement the composition mode Plus with Neon.Benjamin Poulain2010-08-255-22/+83
|/ | | | | | | | | On the benchmark tst_QPainter::compositionModes(), this patches gives the following improvements: -300x300:opaque: 390% -300x300:!opaque: 1085% Reviewed-by: Samuel Rødal
* Fix mispositioned text with QStaticText and OpenVG graphics systemEskil Abrahamsen Blomfeldt2010-08-241-2/+5
| | | | | | | | | | | The OpenVG paint engine, like the OpenGL2 paint engine, supports caching the untransformed glyphs and transforming them as they are drawn. Since we would pretransform the positions of the glyphs, the transformation would be applied twice, thus making the glyphs appear in the wrong location when the painter had a transform set. Task-number: QTBUG-13049 Reviewed-by: Gunnar
* Crash in QX11PaintEngine::drawPixmapCarlos Manuel Duclos Vergara2010-08-181-0/+2
| | | | | | | | | | We receive a pixmap as a const reference and then we convert it to an X11 pixmap. This conversion could fail for many reasons, however we were not looking at the result of this conversion. This patch was contributed by Christoph Feck from KDE. Task-number: QTBUG-12826 Reviewed-by: Samuel