diff options
author | Shawn Rutledge <shawn.rutledge@qt.io> | 2017-08-08 08:18:13 +0200 |
---|---|---|
committer | Shawn Rutledge <shawn.rutledge@qt.io> | 2017-08-08 12:49:44 +0200 |
commit | 2329a3145e59c16b5bbc37cedad7e67e16f14fb8 (patch) | |
tree | 73900588daab4c2c91ef0ff6566818905375ca85 /src/quick/scenegraph/util/qsgatlastexture.cpp | |
parent | d0eb6f9e07156880c6d9de4b98b2e4abfc4a0bfb (diff) | |
parent | 432e27ae092397cb2154f48103e729852c38cf2d (diff) |
Merge remote-tracking branch 'origin/dev' into wip/pointerhandler
Change-Id: I0af7b0c3e0a21aae68c82ec11c5ca579c1661ce9
Diffstat (limited to 'src/quick/scenegraph/util/qsgatlastexture.cpp')
-rw-r--r-- | src/quick/scenegraph/util/qsgatlastexture.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/quick/scenegraph/util/qsgatlastexture.cpp b/src/quick/scenegraph/util/qsgatlastexture.cpp index 22f0b13f46..d5f836a525 100644 --- a/src/quick/scenegraph/util/qsgatlastexture.cpp +++ b/src/quick/scenegraph/util/qsgatlastexture.cpp @@ -116,7 +116,7 @@ QSGTexture *Manager::create(const QImage &image, bool hasAlphaChannel) Texture *t = 0; if (image.width() < m_atlas_size_limit && image.height() < m_atlas_size_limit) { if (!m_atlas) - m_atlas = new Atlas(m_atlas_size); + m_atlas = new Atlas(m_atlas_size, this); // t may be null for atlas allocation failure t = m_atlas->create(image); if (t && !hasAlphaChannel && t->hasAlphaChannel()) @@ -125,8 +125,9 @@ QSGTexture *Manager::create(const QImage &image, bool hasAlphaChannel) return t; } -Atlas::Atlas(const QSize &size) - : m_allocator(size) +Atlas::Atlas(const QSize &size, QObject *parent) + : QObject(parent) + , m_allocator(size) , m_texture_id(0) , m_size(size) , m_atlas_transient_image_threshold(0) |