aboutsummaryrefslogtreecommitdiffstats
path: root/src/quick/scenegraph/util/qsgpainternode.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Added QSGPainterNode abstraction to QSGAdaptationLayerAndy Nichols2014-08-271-427/+0
| | | | | | | | | This allows the scenegraph backend to customize how QSGPainterNodes are rendered. Change-Id: I640dcf121d0be6bda615cf30591d502329fc89d0 Reviewed-by: Lars Knoll <lars.knoll@digia.com> Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
* Update license headers and add new licensesJani Heikkinen2014-08-251-19/+11
| | | | | | | | | - Renamed LICENSE.LGPL to LICENSE.LGPLv21 - Added LICENSE.LGPLv3 & LICENSE.GPLv2 - Removed LICENSE.GPL Change-Id: I84a565e2e0caa3b76bf291a7d188a57a4b00e1b0 Reviewed-by: Jani Heikkinen <jani.heikkinen@digia.com>
* Use qNextPowerOfTwo instead of reimplementing itAllan Sandfeld Jensen2014-07-021-15/+3
| | | | | | | This patch uses the new shared qNextPowerOfTwo implementation introduced in qtbase. Change-Id: I831d056f584897a99df2ceb8c1d840764464e344 Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
* Initialize QSGPaintedNode with an empty size.Gunnar Sletta2014-06-121-1/+0
| | | | | | | | | | Failing to do so would cause it to not update its size when set to 1x1 which in turn would cause it to never update its texture, causing crashes later during rendering. Task-number: QTBUG-39555 Change-Id: I099d9ef2d6968ece21f7c03819abfd6685bec430 Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
* Add node description to painted items.Gunnar Sletta2014-06-121-0/+4
| | | | | Change-Id: I47ad9df1550649131ac5379acbf7d133088c60a8 Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
* Fix crashes and incorrect extension queries on GL3+Laszlo Agocs2014-02-251-3/+3
| | | | | | | | | | | | | | | glGetString(GL_EXTENSIONS) is deprecated in OpenGL 3.0+. This means that in core profiles on 3.2+ (or without the fwd compatibility bit on 3.0/3.1), the call is not supported and may return NULL. This causes a crash in at least one place where we try to blindly strstr the result. The correct solution is to use QOpenGLContext::extensions() and hasExtension() which is prepared to handle GL3+. Change-Id: I52fec7dcee001cdc0933af03f5eed4b7c822b2bb Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com> Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com> Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
* Add Image::mipmap to support mipmapping of images.Gunnar Sletta2014-02-121-1/+0
| | | | | | | | | [ChangeLog][QtQuick] New feature: Image.mipmap Task-number: QTBUG-19961 Change-Id: I13acb2408d5b126790adaf9d324ad4beda1e3646 Reviewed-by: Michael Brasser <michael.brasser@live.com>
* Use one render loop per QQuickWindowGunnar Sletta2013-10-301-3/+3
| | | | | | | | | | | | | | | | | | | See the task for the full reasoning behind this patch. The threaded renderloop has been refactored to have one window per thread. This is mostly a simplification of the current code path where for loops over multiple windows are turned into if (window). The QSGContext has been split into two classes, QSGRenderContext for which there is one per OpenGLContext. The rest of the patch is name changes and a couple of cleanups in the hopes of simplifying this change. Task-number: QTBUG-33993 Change-Id: I31c81f9694d7da7474a72333169be38de62613c4 Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
* Fix license headers of QtQuick sources.Gunnar Sletta2013-09-301-1/+1
| | | | | Change-Id: I3750c47640bf21c3567c5fa1c4667e3e2552942e Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* Remove slow and buggy sub-image codePaul Olav Tvete2013-04-161-30/+1
| | | | | | | | | | | The code was probably sub-optimal in most cases, and it broke on GLES 2 when using the BGRA texture extension. Done with Gunnar. Task-number: QTBUG-30656 Change-Id: I92f74cd39f408f145629bc0eb6f3ff43d2f4f000 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
* Merge remote-tracking branch 'origin/stable' into devFrederik Gladhorn2013-02-181-2/+1
|\ | | | | | | Change-Id: I33db683ebf12248b2ed14eeaf65c4bcade14bfbf
| * Remove use of QPainter::HighQualityAntialiasing. It has no effect.Gunnar Sletta2013-02-121-2/+1
| | | | | | | | | | Change-Id: I7e1d07a9f34d6edf9dbe3449d34636f700218532 Reviewed-by: Samuel Rødal <samuel.rodal@digia.com>
* | Dereference the QImage once the corresponding texture is bound.Michael Brasser2013-02-011-1/+1
|/ | | | | | | | | | | | | | We do not require a reference here, as the texture is only bound once. It is the texture factory that is reused (when QQuickWIndow::setPersistentSceneGraph(false) is set and the window is hidden and then re-exposed). With this patch it becomes trivial to create a custom QSGContextPlugin with a texture factory that does not retain the QImage, freeing up memory. This is useful in the case of an embedded system with only a single window that is never hidden or re-exposed. Change-Id: I1cfa6efc3a2e9e641b456bf90c55d563061757b8 Reviewed-by: Gunnar Sletta <gunnar.sletta@digia.com>
* Update copyright year in Digia's license headersSergio Ahumada2013-01-101-1/+1
| | | | | | Change-Id: I6c3bd7bebe3d62d1cfd0fa6334544c9db8398c76 Reviewed-by: Akseli Salovaara <akseli.salovaara@digia.com> Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com>
* Change copyrights from Nokia to DigiaIikka Eklund2012-09-231-24/+24
| | | | | | | Change copyrights and license headers from Nokia to Digia Change-Id: Ie7f5d49ed8235d7a7845ab68f99ad1c220e64d5c Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* Fix resizing of QQuickPaintedItems that use FBOs.Kim Motoyoshi Kalland2012-06-011-0/+4
| | | | | | | Task-number: QTBUG-25472 Change-Id: Icc8d0f93841a76bbc92d09e0bf96f147ac64a8c6 Reviewed-by: Yoann Lopes <yoann.lopes@nokia.com>
* Properly swizzle texture data before upload in QQuickPaintedItem.Samuel Rødal2012-04-031-0/+5
| | | | | | | | | We already did this properly in QSGPlainTexture, need to do it in QSGPainterTexture as well, or red and blue channels will be swapped on OpenGL ES 2. Change-Id: I8b17a359b80d6c2e3b89d9c1d4c3d388a3ad1081 Reviewed-by: Kim M. Kalland <kim.kalland@nokia.com>
* Rename QDeclarative symbols to QQuick and QQmlMatthew Vogt2012-02-241-1/+1
| | | | | | | | | | | | | Symbols beginning with QDeclarative are already exported by the quick1 module. Users can apply the bin/rename-qtdeclarative-symbols.sh script to modify client code using the previous names of the renamed symbols. Task-number: QTBUG-23737 Change-Id: Ifaa482663767634931e8711a8e9bf6e404859e66 Reviewed-by: Martin Jones <martin.jones@nokia.com>
* Fix for QTBUG-23862 - Blank screen in ViewportChristopher Ham2012-02-101-5/+4
| | | | | | | | | | This patch fixes an issue that causes Qt3D's Viewport to be blank when its renderMode property is set to BufferedRender. (QSGPainterNode's RenderTarget is set to FramebufferObject) Task-number: QTBUG-23862 Change-Id: Ic7a333f79ecf1aa153ef42e213644a17243a3580 Reviewed-by: Sarah Jane Smith <sarah.j.smith@nokia.com> Reviewed-by: Yoann Lopes <yoann.lopes@nokia.com>
* Remove "All rights reserved" line from license headers.Jason McDonald2012-01-301-1/+1
| | | | | | | | | | As in the past, to avoid rewriting various autotests that contain line-number information, an extra blank line has been inserted at the end of the license text to ensure that this commit does not change the total number of lines in the license header. Change-Id: If39bd256b0fa85eba17ea30f8ab87ea27d758908 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Update obsolete contact address.Jason McDonald2012-01-231-1/+1
| | | | | | | | Replace Nokia contact email address with Qt Project website. Change-Id: I6a730abc0c396fb545a48b2d6938abedac2e3f1c Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com> Reviewed-by: Alan Alpert <alan.alpert@nokia.com>
* Update copyright year in Nokia copyright headers.Jason McDonald2012-01-171-1/+1
| | | | | | | | Update copyright headers from before 2011, and a couple of new ones that were merged after the previous change to copyright headers. Change-Id: Ia76e08e2734afa4ef3f1207dbcda5ff3bc81b366 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Fix crash on null Qimage in QSGPainterNode::paintMorten Johan Sorvig2012-01-051-0/+3
| | | | | | | | Creating a QPainter on a null image is not allowed, return early if this is the case. Change-Id: I56f30c0fd84eefc1676d6b980f77269abace07ce Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
* Say hello to QtQuick moduleKent Hansen2011-12-021-0/+464
This change moves the QtQuick 2 types and C++ API (including SceneGraph) to a new module (AKA library), QtQuick. 99% of this change is moving files from src/declarative to src/quick, and from tests/auto/declarative to tests/auto/qtquick2. The loading of QtQuick 2 ("import QtQuick 2.0") is now delegated to a plugin, src/imports/qtquick2, just like it's done for QtQuick 1. All tools, examples, and tests that use QtQuick C++ API have gotten "QT += quick" or "QT += quick-private" added to their .pro file. A few additional internal QtDeclarative classes had to be exported (via Q_DECLARATIVE_PRIVATE_EXPORT) since they're needed by the QtQuick 2 implementation. The old header locations (e.g. QtDeclarative/qquickitem.h) will still be supported for some time, but will produce compile-time warnings. (To avoid the QtQuick implementation using the compatibility headers (since QtDeclarative's includepath comes first), a few include statements were modified, e.g. from "#include <qsgnode.h>" to "#include <QtQuick/qsgnode.h>".) There's a change in qtbase that automatically adds QtQuick to the module list if QtDeclarative is used. Together with the compatibility headers, this should help reduce the migration pain for existing projects. In theory, simply getting an existing QtDeclarative-based project to compile and link shouldn't require any changes for now -- but porting to the new scheme is of course recommended, and will eventually become mandatory. Task-number: QTBUG-22889 Reviewed-by: Lars Knoll <lars.knoll@nokia.com> Change-Id: Ia52be9373172ba2f37e7623231ecb060316c96a7 Reviewed-by: Kent Hansen <kent.hansen@nokia.com> Reviewed-by: Sergio Ahumada <sergio.ahumada@nokia.com>