summaryrefslogtreecommitdiffstats
path: root/src/gui/rhi/qrhigles2_p_p.h
diff options
context:
space:
mode:
authorLaszlo Agocs <laszlo.agocs@qt.io>2019-11-26 12:43:56 +0100
committerLaszlo Agocs <laszlo.agocs@qt.io>2019-11-27 19:07:36 +0100
commit64760504e79c3069d99b5e852688a2589ec22028 (patch)
tree05524e084cbd5f9b08108b072d87209409d74e47 /src/gui/rhi/qrhigles2_p_p.h
parent48d2ffd39786b2decad76132158aeba172a3b8a8 (diff)
rhi: Allow testing QRhiRenderPassDescriptors for compatibility
For Metal and Vulkan this needs actual work because that's where the concept of renderpass descriptors is relevant. GL and D3D can just return true always. The big benefit of this is that Qt Quick can now compare renderpass descriptors via isCompatible() for its pipeline cache (similarly to how it is already using isLayoutCompatible() for srbs), and so renderpass descriptors for layers (Item.layer, ShaderEffect) will typically be compatible and so can pick up pipelines created by other layers from the cache. Also add autotests for shader resource binding and renderpass descriptor compatibility. Task-number: QTBUG-80318 Change-Id: I0008bc51c4ee13b0113d2c8caf799e1257f18a18 Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
Diffstat (limited to 'src/gui/rhi/qrhigles2_p_p.h')
-rw-r--r--src/gui/rhi/qrhigles2_p_p.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/gui/rhi/qrhigles2_p_p.h b/src/gui/rhi/qrhigles2_p_p.h
index cc945876e6..b0f5e340fb 100644
--- a/src/gui/rhi/qrhigles2_p_p.h
+++ b/src/gui/rhi/qrhigles2_p_p.h
@@ -185,6 +185,7 @@ struct QGles2RenderPassDescriptor : public QRhiRenderPassDescriptor
QGles2RenderPassDescriptor(QRhiImplementation *rhi);
~QGles2RenderPassDescriptor();
void release() override;
+ bool isCompatible(const QRhiRenderPassDescriptor *other) const override;
};
struct QGles2RenderTargetData