summaryrefslogtreecommitdiffstats
path: root/src/plugins/platforms/direct2d
Commit message (Collapse)AuthorAgeFilesLines
...
* | Direct2D QPA: Disable vsyncLouai Al-Khanji2014-04-251-1/+1
| | | | | | | | | | | | | | | | | | We shouldn't block the whole gui thread for vsyncing. This can slow things down a lot if a lot of drawing happens. Change-Id: Ie459f9dee2271e7908e2b7f56873393c67f82836 Reviewed-by: Risto Avila <risto.avila@digia.com> Reviewed-by: Andrew Knight <andrew.knight@digia.com>
* | Direct2D QPA: Do not attempt to create swap chain for desktop widgetLouai Al-Khanji2014-04-241-0/+3
| | | | | | | | | | | | | | | | | | We can't and don't need to create a swap chain for the desktop widget. Change-Id: I84cd5c753710af09bab5c7afc27e202e661343db Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com> Reviewed-by: Andrew Knight <andrew.knight@digia.com> Reviewed-by: Risto Avila <risto.avila@digia.com>
* | Direct2D QPA: Fix text drawing with brush but no penLouai Al-Khanji2014-04-161-2/+2
| | | | | | | | | | | | | | | | | | We were incorrectly bailing out early in the text drawing code when there was no pen. This is incorrect as drawing with only a brush should be possible. Change-Id: I94eaadd3cf6c4d82033b5d74d7ca47a05601083f Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* | Direct2D QPA: Refactor code to reduce code duplicationLouai Al-Khanji2014-04-161-102/+120
| | | | | | | | | | | | | | | | | | Refactor duplicate logic in painterPathToPathGeometry and vectorPathToID2D1PathGeometry into one utility class. At the same time make the naming of the two functions consistent with each other. Change-Id: I03c8fc183863473b7337223e51835cf080914a41 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* | Direct2D QPA: Optimize rectangle fills.Louai Al-Khanji2014-04-161-6/+18
| | | | | | | | | | | | | | Detect rectangle hints in the QVectorPath and react accordingly. Change-Id: Ic72ce0c46d10e995c0824972854e2d88162eae45 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* | Direct2D QPA: Improve gradient supportLouai Al-Khanji2014-04-161-10/+87
|/ | | | | | | | | This change adds support for those gradients which can be expressed using Direct2D. At the moment this means linear and radial gradient with pad spread only. Change-Id: Ib1b1bc38a793dd826a259bbf8a7b31c25906dd59 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* Fix Direct2D clipping when Qt::WA_OpaquePaintEvent is trueRisto Avila2014-03-141-11/+40
| | | | | | | | | | | | Changed clip rectangle handling from bounding rect to region. Now also sub region rectangles are taken in to account. Task-number: QTBUG-37199 Change-Id: I9e09376e2c6d3fee8f85db753295a6138a03096f Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com> Reviewed-by: Janne Koskinen <janne.p.koskinen@digia.com> Reviewed-by: Louai Al-Khanji <louai.al-khanji@digia.com> Reviewed-by: Andrew Knight <andrew.knight@digia.com>
* Move Direct2D paint engine on top of QPaintEngineExLouai Al-Khanji2014-01-313-468/+531
| | | | | | | | | | | | | | | | | Make QWindowsDirect2DPaintEngine a subclass of QPaintEngineEx instead of QPaintEngine like the other paint engines inside Qt. This should both be faster and better supported, as the code paths handling QPaintEngineEx in QPainter are tested more. Additionally the visual output is closer to the raster engine, as all primitives are drawn using the same mechanism, resulting in fewer off-by-one-pixel errors. This change also makes designer work mostly correctly, apart from some remaining clipping bugs. Change-Id: I53d36c08e73883ff35e389d57f9d30b482fc6721 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* Improve direct2d backing store implementationLouai Al-Khanji2014-01-277-166/+288
| | | | | | | | | | | | | | | | | | | | | | Add a per-window swap chain to a QPlatformWindow subclass instead of tying it to the backing store. This is needed to support native widgets (as opposed to alien widgets). Change the backing store to draw to an intermediate pixmap and flush to the requested window by using the per-window swap chain. This also opens the door for faster window presentation later on by using the swap chain more intelligently. Also add a changelog entry for the direct2d plugin, which was omitted earlier. [ChangeLog][QtGui][Windows] Introduce experimental direct2d platform plugin for Windows. This plugin shares most code with the current windows plugin, but substitutes a direct2d-based paint engine for window backing stores and pixmaps. Change-Id: I5f54e7e4c1fb15b1639bd26b712fb40ac141e4ac Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* Fix Q_ASSERT in direct2d qpa pluginLouai Al-Khanji2014-01-241-1/+1
| | | | | | | | When calling end the refcount should be greater than zero, as calls to begin/end should match. Change-Id: I49adbf6f9f1c21cb60985ba4e02574e6c0841b74 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* Add new direct2d platform pluginLouai Al-Khanji2014-01-1022-0/+3328
This is an alternative plugin for the windows platform. It shares most code with the current windows plugin, but substitutes a direct2d-based paint engine for window backing stores and pixmaps. Change-Id: I78fafd9c5871fa090b49436f5b40ec80f8789f8b Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>