14#include <QtQuick/qsgsimplerectnode.h>
15#include <QtQuick/qsgsimpletexturenode.h>
16#include <QtQuick/qsgrendernode.h>
23 m_opacityState.
push(1.0f);
38 m_stateMap[node] = currentState(node);
44 m_transformState.
pop();
50 if (m_clipState.
size() == 0 || (m_clipState.
size() == 1 && m_clipState.
top().
isNull())) {
57 m_stateMap[node] = currentState(node);
64 if (m_clipState.
size() == 0 || (m_clipState.
size() == 1 && m_clipState.
top().
isNull()))
93 m_stateMap[node] = currentState(node);
140 m_stateMap[node] = currentState(node);
148#if QT_CONFIG(quick_sprite)
151 return updateRenderableNode(QSGSoftwareRenderableNode::SpriteNode, node);
171 m_opacityState.
clear();
173 m_transformState.
clear();
175 auto parentNode = node->
parent();
178 if ((!parentNode || isNodeRemoved ) && m_stateMap.
contains(node))
179 parentNode = m_stateMap[node].parent;
182 if (parentNode && m_stateMap.
contains(parentNode)) {
183 auto state = m_stateMap[parentNode];
187 m_hasClip =
state.hasClip;
190 m_opacityState.
push(1.0f);
204 switch (node->
type()) {
262QSGSoftwareRenderableNodeUpdater::NodeState QSGSoftwareRenderableNodeUpdater::currentState(
QSGNode *node)
const
265 state.opacity = m_opacityState.
top();
267 state.hasClip = m_hasClip;
268 state.transform = m_transformState.
top();
bool remove(const Key &key)
Removes the item that has the key from the hash.
bool contains(const Key &key) const noexcept
Returns true if the hash contains an item with the key; otherwise returns false.
qsizetype size() const noexcept
QTransform toTransform() const
Returns the conventional Qt 2D transformation matrix that corresponds to this matrix.
constexpr QRect toRect() const noexcept
Returns a QRect based on the values of this rectangle.
The QRegion class specifies a clip region for a painter.
QRegion intersected(const QRegion &r) const
The QSGClipNode class implements the clipping functionality in the scene graph.
QRectF clipRect() const
Returns the clip rect of this node.
The QSGGeometryNode class is used for all rendered content in the scene graph.
The QSGImageNode class is provided for convenience to easily draw textured content using the QML scen...
void visitChildren(QSGNode *node)
\group qtquick-scenegraph-nodes \title Qt Quick Scene Graph Node classes
Flags flags() const
Returns the set of flags for this node.
QSGNode * parent() const
Returns the parent node of this node.
NodeType type() const
Returns the type of this node.
The QSGOpacityNode class is used to change opacity of nodes.
qreal opacity() const
Returns this opacity node's opacity.
The QSGRectangleNode class is a convenience class for drawing solid filled rectangles using scenegrap...
The QSGRenderNode class represents a set of custom rendering commands targeting the graphics API that...
The QSGRootNode is the toplevel root of any scene graph.
The QSGSimpleRectNode class is a convenience class for drawing solid filled rectangles using scenegra...
The QSGSimpleTextureNode class is provided for convenience to easily draw textured content using the ...
QSGSoftwareRenderableNodeUpdater(QSGAbstractSoftwareRenderer *renderer)
void endVisit(QSGTransformNode *) override
virtual ~QSGSoftwareRenderableNodeUpdater()
bool visit(QSGTransformNode *) override
void updateNodes(QSGNode *node, bool isNodeRemoved=false)
virtual void accept(QSGNodeVisitorEx *)=0
T & top()
Returns a reference to the stack's top item.
T pop()
Removes the top item from the stack and returns it.
void push(const T &t)
Adds element t to the top of the stack.
Combined button and popup list for selecting options.
GLsizei const GLfloat * v
[13]
QSvgRenderer * renderer
[0]