Skip to content

Commit

Permalink
MetalDevice: Fix depth not storing
Browse files Browse the repository at this point in the history
  • Loading branch information
stenzek committed Dec 9, 2023
1 parent 993c8f9 commit 00a1ffe
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/util/metal_device.mm
Original file line number Diff line number Diff line change
Expand Up @@ -1778,6 +1778,7 @@ static void DumpShader(u32 n, const std::string_view& suffix, const std::string_
{
MetalTexture* const RT = m_current_render_targets[i];
desc.colorAttachments[i].texture = RT->GetMTLTexture();
desc.colorAttachments[i].storeAction = MTLStoreActionStore;
RT->SetUseFenceCounter(m_current_fence_counter);

switch (RT->GetState())
Expand Down Expand Up @@ -1814,6 +1815,7 @@ static void DumpShader(u32 n, const std::string_view& suffix, const std::string_
if (MetalTexture* DS = m_current_depth_target)
{
desc.depthAttachment.texture = m_current_depth_target->GetMTLTexture();
desc.depthAttachment.storeAction = MTLStoreActionStore;
DS->SetUseFenceCounter(m_current_fence_counter);

switch (DS->GetState())
Expand Down

0 comments on commit 00a1ffe

Please sign in to comment.