Graphics/FrameGraph: Fix pipeline barrier from output to input

This commit is contained in:
SirLynix 2022-04-08 13:36:07 +02:00
parent b7493f01bf
commit ca9854d06a
1 changed files with 3 additions and 3 deletions

View File

@ -297,8 +297,8 @@ namespace Nz
if (barrier.layout != TextureLayout::Undefined)
throw std::runtime_error("layout mismatch");
barrier.access |= MemoryAccess::ColorRead | MemoryAccess::ColorWrite;
barrier.stages |= PipelineStage::ColorOutput;
barrier.access |= MemoryAccess::ShaderRead;
barrier.stages |= PipelineStage::FragmentShader;
barrier.layout = TextureLayout::ColorInput;
}
@ -308,7 +308,7 @@ namespace Nz
if (barrier.layout != TextureLayout::Undefined)
throw std::runtime_error("layout mismatch");
barrier.access |= MemoryAccess::ColorRead | MemoryAccess::ColorWrite;
barrier.access |= MemoryAccess::ColorWrite;
barrier.stages |= PipelineStage::ColorOutput;
barrier.layout = TextureLayout::ColorOutput;
}