From: Michael Brasser Date: Tue, 11 Feb 2014 14:41:36 +0000 (-0600) Subject: Provide scenegraph backend API for marking scenegraph nodes dirty. X-Git-Tag: upstream/5.2.2^2~5 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=1ec525e7e011a8881ec7d90e34876d5bf5fb2fc8;p=platform%2Fupstream%2Fqtdeclarative.git Provide scenegraph backend API for marking scenegraph nodes dirty. Prior to Qt 5.2 tracking of dirty state was automatically handled by QSGNode. With Qt 5.2 this approach has changed. Moving forward render state is ideally tracked outside of QSGNode; however, we continue to provide a way to track it in the node itself, to support custom renderers and the default node updater. Change-Id: I78907caee1b64b94a2bae2d8b577210f1955a431 Reviewed-by: Gunnar Sletta --- diff --git a/src/quick/scenegraph/coreapi/qsgnode.h b/src/quick/scenegraph/coreapi/qsgnode.h index 60e7652..f85184d 100644 --- a/src/quick/scenegraph/coreapi/qsgnode.h +++ b/src/quick/scenegraph/coreapi/qsgnode.h @@ -161,6 +161,7 @@ protected: private: friend class QSGRootNode; friend class QSGBatchRenderer::Renderer; + friend class QSGRenderer; void init(); void destroy(); diff --git a/src/quick/scenegraph/coreapi/qsgrenderer_p.h b/src/quick/scenegraph/coreapi/qsgrenderer_p.h index 43811e6..12ba381 100644 --- a/src/quick/scenegraph/coreapi/qsgrenderer_p.h +++ b/src/quick/scenegraph/coreapi/qsgrenderer_p.h @@ -148,6 +148,7 @@ protected: void addNodesToPreprocess(QSGNode *node); void removeNodesToPreprocess(QSGNode *node); + void markNodeDirtyState(QSGNode *node, QSGNode::DirtyState state) { node->m_dirtyState |= state; } QColor m_clear_color; ClearMode m_clear_mode;