1
0
mirror of https://github.com/doitsujin/dxvk.git synced 2025-01-19 05:52:11 +01:00

[dxvk] Introduce HasStorageDescriptors to signify pipeline side effects

This commit is contained in:
Philip Rebohle 2019-10-13 00:24:16 +02:00
parent c5676d3108
commit baf81473a6
No known key found for this signature in database
GPG Key ID: C8CC613427A31C99
3 changed files with 4 additions and 12 deletions

View File

@ -4356,9 +4356,7 @@ namespace dxvk {
if (m_flags.test(DxvkContextFlag::DirtyDrawBuffer) && Indirect)
this->trackDrawBuffer();
if (m_state.gp.flags.any(
DxvkGraphicsPipelineFlag::HasFsStorageDescriptors,
DxvkGraphicsPipelineFlag::HasVsStorageDescriptors))
if (m_state.gp.flags.test(DxvkGraphicsPipelineFlag::HasStorageDescriptors))
this->commitGraphicsPostBarriers();
}

View File

@ -32,13 +32,8 @@ namespace dxvk {
if (m_shaders.gs != nullptr && m_shaders.gs->hasCapability(spv::CapabilityTransformFeedback))
m_flags.set(DxvkGraphicsPipelineFlag::HasTransformFeedback);
VkShaderStageFlags stoStages = m_layout->getStorageDescriptorStages();
if (stoStages & VK_SHADER_STAGE_FRAGMENT_BIT)
m_flags.set(DxvkGraphicsPipelineFlag::HasFsStorageDescriptors);
if (stoStages & ~VK_SHADER_STAGE_FRAGMENT_BIT)
m_flags.set(DxvkGraphicsPipelineFlag::HasVsStorageDescriptors);
if (m_layout->getStorageDescriptorStages())
m_flags.set(DxvkGraphicsPipelineFlag::HasStorageDescriptors);
m_common.msSampleShadingEnable = m_shaders.fs != nullptr && m_shaders.fs->hasCapability(spv::CapabilitySampleRateShading);
m_common.msSampleShadingFactor = 1.0f;

View File

@ -22,8 +22,7 @@ namespace dxvk {
*/
enum class DxvkGraphicsPipelineFlag {
HasTransformFeedback,
HasFsStorageDescriptors,
HasVsStorageDescriptors,
HasStorageDescriptors,
};
using DxvkGraphicsPipelineFlags = Flags<DxvkGraphicsPipelineFlag>;