diff options
author | Laszlo Agocs <laszlo.agocs@qt.io> | 2023-02-17 13:16:20 +0100 |
---|---|---|
committer | Laszlo Agocs <laszlo.agocs@qt.io> | 2023-02-20 18:06:32 +0100 |
commit | 6cf3447f1d119a5e61c5abf3ac546ec4746ee5fe (patch) | |
tree | f930c2c1ed84cb6b47491712efcdff27d6e14025 /src/gui/rhi/qrhivulkan.cpp | |
parent | c6b7737436fb375b3b637e05076d82628d616e4c (diff) |
rhi: backends: Get color attachment count in a saner way
Also bring all list-like data to the same level when it comes
to the interface exposed in QRhi*.
Change-Id: I90296a49ff1f52c1ce4e787167c99006fab3c4c3
Reviewed-by: Andy Nichols <andy.nichols@qt.io>
Diffstat (limited to 'src/gui/rhi/qrhivulkan.cpp')
-rw-r--r-- | src/gui/rhi/qrhivulkan.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/gui/rhi/qrhivulkan.cpp b/src/gui/rhi/qrhivulkan.cpp index ea7d40fef2..ca0c81a756 100644 --- a/src/gui/rhi/qrhivulkan.cpp +++ b/src/gui/rhi/qrhivulkan.cpp @@ -6493,8 +6493,7 @@ bool QVkTextureRenderTarget::create() if (d.fb) destroy(); - const bool hasColorAttachments = m_desc.cbeginColorAttachments() != m_desc.cendColorAttachments(); - Q_ASSERT(hasColorAttachments || m_desc.depthTexture()); + Q_ASSERT(m_desc.colorAttachmentCount() > 0 || m_desc.depthTexture()); Q_ASSERT(!m_desc.depthStencilBuffer() || !m_desc.depthTexture()); const bool hasDepthStencil = m_desc.depthStencilBuffer() || m_desc.depthTexture(); |