diff options
author | Frederik Gladhorn <frederik.gladhorn@digia.com> | 2013-10-24 12:49:23 +0200 |
---|---|---|
committer | Frederik Gladhorn <frederik.gladhorn@digia.com> | 2013-10-24 12:49:23 +0200 |
commit | 648d4ae6a3591e916f175e32c12a2ea4f8edb6a9 (patch) | |
tree | ecd3aaedd0022bc2df0b6bbc24e10fc21a8adb6e /src/quick/scenegraph/qsgdefaultimagenode.cpp | |
parent | 9443e72a92a4d1d717e931ee9149c1e3652e9f53 (diff) | |
parent | aa1760f84bd711cf56159075630fb71d38a4087b (diff) |
Merge remote-tracking branch 'origin/stable' into dev
Change-Id: I06835511fa131f65470bd9b177cdce75f51b385a
Diffstat (limited to 'src/quick/scenegraph/qsgdefaultimagenode.cpp')
-rw-r--r-- | src/quick/scenegraph/qsgdefaultimagenode.cpp | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/quick/scenegraph/qsgdefaultimagenode.cpp b/src/quick/scenegraph/qsgdefaultimagenode.cpp index 349a92ac7f..11d0e5dbeb 100644 --- a/src/quick/scenegraph/qsgdefaultimagenode.cpp +++ b/src/quick/scenegraph/qsgdefaultimagenode.cpp @@ -298,15 +298,13 @@ void QSGDefaultImageNode::setHorizontalWrapMode(QSGTexture::WrapMode wrapMode) void QSGDefaultImageNode::setTexture(QSGTexture *texture) { - if (texture == m_material.texture()) - return; + Q_ASSERT(texture); m_material.setTexture(texture); m_materialO.setTexture(texture); m_smoothMaterial.setTexture(texture); - // Texture cleanup - if (texture) - m_material.setFlag(QSGMaterial::Blending, texture->hasAlphaChannel()); + m_material.setFlag(QSGMaterial::Blending, texture->hasAlphaChannel()); + markDirty(DirtyMaterial); // Because the texture can be a different part of the atlas, we need to update it... |