From 9aed82c00a73b9c70125edb90a675cbe70f91306 Mon Sep 17 00:00:00 2001 From: Philip Rebohle Date: Mon, 28 Oct 2024 13:30:52 +0100 Subject: [PATCH] [dxvk] Fix nonsensical layout check in ensureImageCompatibility Derp, this fixes some unnecessary barriers. --- src/dxvk/dxvk_context.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/dxvk/dxvk_context.cpp b/src/dxvk/dxvk_context.cpp index 6fe9e4306..e75356de4 100644 --- a/src/dxvk/dxvk_context.cpp +++ b/src/dxvk/dxvk_context.cpp @@ -1492,7 +1492,7 @@ namespace dxvk { // Check if we need to insert a barrier and update image properties bool isAccessAndLayoutCompatible = (image->info().stages & usageInfo.stages) == usageInfo.stages && (image->info().access & usageInfo.access) == usageInfo.access - && (usageInfo.layout && image->info().layout == usageInfo.layout); + && (!usageInfo.layout || image->info().layout == usageInfo.layout); // If everything matches already, no need to do anything. Only ensure // that the stable adress bit is respected if set for the first time.