summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTriang3l <triang3l@yandex.ru>2023-05-05 21:38:45 +0300
committerTriang3l <triang3l@yandex.ru>2023-05-05 21:38:45 +0300
commited64e3072bde74955c79b9f3b0030c133648d702 (patch)
tree4b88ab691d03c79a082d2b14d9842b93ae343825
parent0e81293b02457f43702157c5b6de054644ab0797 (diff)
[GPU] Remove implicit bool cast in memexport checks
-rw-r--r--src/xenia/gpu/d3d12/d3d12_command_processor.cc4
-rw-r--r--src/xenia/gpu/vulkan/vulkan_command_processor.cc2
2 files changed, 3 insertions, 3 deletions
diff --git a/src/xenia/gpu/d3d12/d3d12_command_processor.cc b/src/xenia/gpu/d3d12/d3d12_command_processor.cc
index 90427f5f7..814a74a7c 100644
--- a/src/xenia/gpu/d3d12/d3d12_command_processor.cc
+++ b/src/xenia/gpu/d3d12/d3d12_command_processor.cc
@@ -2125,7 +2125,7 @@ bool D3D12CommandProcessor::IssueDraw(xenos::PrimitiveType primitive_type,
return false;
}
pipeline_cache_->AnalyzeShaderUcode(*vertex_shader);
- bool memexport_used_vertex = vertex_shader->memexport_eM_written();
+ bool memexport_used_vertex = vertex_shader->memexport_eM_written() != 0;
// Pixel shader analysis.
bool primitive_polygonal = draw_util::IsPrimitivePolygonal(regs);
@@ -2154,7 +2154,7 @@ bool D3D12CommandProcessor::IssueDraw(xenos::PrimitiveType primitive_type,
}
}
bool memexport_used_pixel =
- pixel_shader && pixel_shader->memexport_eM_written();
+ pixel_shader && (pixel_shader->memexport_eM_written() != 0);
bool memexport_used = memexport_used_vertex || memexport_used_pixel;
if (!BeginSubmission(true)) {
diff --git a/src/xenia/gpu/vulkan/vulkan_command_processor.cc b/src/xenia/gpu/vulkan/vulkan_command_processor.cc
index 7136505b2..7115929f4 100644
--- a/src/xenia/gpu/vulkan/vulkan_command_processor.cc
+++ b/src/xenia/gpu/vulkan/vulkan_command_processor.cc
@@ -2175,7 +2175,7 @@ bool VulkanCommandProcessor::IssueDraw(xenos::PrimitiveType prim_type,
return false;
}
pipeline_cache_->AnalyzeShaderUcode(*vertex_shader);
- bool memexport_used_vertex = vertex_shader->memexport_eM_written();
+ bool memexport_used_vertex = vertex_shader->memexport_eM_written() != 0;
// Pixel shader analysis.
bool primitive_polygonal = draw_util::IsPrimitivePolygonal(regs);