summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMichal Klocek <michal.klocek@qt.io>2020-05-05 13:36:09 +0200
committerMichal Klocek <michal.klocek@qt.io>2020-05-14 17:35:43 +0200
commit415eaeb68f275a85ec9537c768c29f96defb3602 (patch)
treefab99e07904c80885061a7e43bbfd7f54b2eafb0 /src
parente8c14a21bde3ccd629ff9aa40460d9b09582883b (diff)
Fix compilation with declarative 6.0
Since 76f783c23fa we need to provide comparisonKey for QSGTexture Change-Id: Ia993f33cb5a87513f912d62c2166bf4938372fc6 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
Diffstat (limited to 'src')
-rw-r--r--src/core/compositor/delegated_frame_node.cpp6
-rw-r--r--src/core/compositor/display_gl_output_surface_qsg.cpp1
2 files changed, 7 insertions, 0 deletions
diff --git a/src/core/compositor/delegated_frame_node.cpp b/src/core/compositor/delegated_frame_node.cpp
index 4d74937d9..d41d21e93 100644
--- a/src/core/compositor/delegated_frame_node.cpp
+++ b/src/core/compositor/delegated_frame_node.cpp
@@ -125,6 +125,12 @@ public:
QSize textureSize() const override { return m_textureSize; }
bool hasAlphaChannel() const override { return m_hasAlpha; }
bool hasMipmaps() const override { return false; }
+ int comparisonKey() const override
+ {
+ if (m_textureId)
+ return m_textureId;
+ return int(qintptr(this));
+ }
void bind() override;
private:
diff --git a/src/core/compositor/display_gl_output_surface_qsg.cpp b/src/core/compositor/display_gl_output_surface_qsg.cpp
index 2f7b3de84..2ed24ef1d 100644
--- a/src/core/compositor/display_gl_output_surface_qsg.cpp
+++ b/src/core/compositor/display_gl_output_surface_qsg.cpp
@@ -76,6 +76,7 @@ public:
QOpenGLFunctions *funcs = context->functions();
funcs->glBindTexture(GL_TEXTURE_2D, m_id);
}
+ int comparisonKey() const override { return m_id; }
private:
uint32_t m_id;