QSGDefaultImageNode: Only set DirtyGeometry if new texture
QSGDefaultImageNode::preprocess() always sets the geometry to dirty even if no new texture was grabbed. Change-Id: Ifb6ce160854aa0a5b9e0f87fbf517b21e86e0ade Task-number: QTBUG-49904 Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
This commit is contained in:
parent
c1bdf81549
commit
9000c04650
|
@ -287,7 +287,8 @@ void QSGDefaultImageNode::preprocess()
|
|||
QSGDynamicTexture *t = qobject_cast<QSGDynamicTexture *>(m_material.texture());
|
||||
if (t) {
|
||||
doDirty = t->updateTexture();
|
||||
updateGeometry();
|
||||
if (doDirty)
|
||||
updateGeometry();
|
||||
}
|
||||
bool alpha = m_material.flags() & QSGMaterial::Blending;
|
||||
if (m_material.texture() && alpha != m_material.texture()->hasAlphaChannel()) {
|
||||
|
|
Loading…
Reference in New Issue