Migrate force_log_printf to new logging (#714)

This commit is contained in:
why-keith 2023-04-12 15:31:34 +01:00 committed by GitHub
parent 072c18a6e3
commit 4be57f4896
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
108 changed files with 401 additions and 399 deletions

View file

@ -225,7 +225,7 @@ VkFormat PipelineCompiler::GetVertexFormat(uint8 format)
case FMT_2_10_10_10:
return VK_FORMAT_R32_UINT; // verified to match OpenGL
default:
forceLog_printf("Unsupported vertex format: %02x", format);
cemuLog_log(LogType::Force, "Unsupported vertex format: {:02x}", format);
assert_dbg();
return VK_FORMAT_UNDEFINED;
}
@ -398,7 +398,7 @@ bool PipelineCompiler::InitShaderStages(VulkanRenderer* vkRenderer, RendererShad
(vkGeometryShader && vkGeometryShader->GetShaderModule() == VK_NULL_HANDLE) ||
(vkPixelShader && vkPixelShader->GetShaderModule() == VK_NULL_HANDLE))
{
forceLog_printf("Vulkan-Info: Pipeline creation failed due to invalid shader(s)");
cemuLog_log(LogType::Force, "Vulkan-Info: Pipeline creation failed due to invalid shader(s)");
return false;
}
@ -921,7 +921,7 @@ bool PipelineCompiler::InitFromCurrentGPUState(PipelineInfo* pipelineInfo, const
VkResult result = vkCreatePipelineLayout(vkRenderer->m_logicalDevice, &pipelineLayoutInfo, nullptr, &m_pipeline_layout);
if (result != VK_SUCCESS)
{
forceLog_printf("%s", fmt::format("Failed to create pipeline layout: {}", result).c_str());
cemuLog_log(LogType::Force, "Failed to create pipeline layout: {}", result);
s_nvidiaWorkaround.unlock();
return false;
}
@ -1041,7 +1041,7 @@ bool PipelineCompiler::Compile(bool forceCompile, bool isRenderThread, bool show
}
else
{
forceLog_printf("Failed to create graphics pipeline. Error %d", (sint32)result);
cemuLog_log(LogType::Force, "Failed to create graphics pipeline. Error {}", (sint32)result);
cemu_assert_debug(false);
return true; // true indicates that caller should no longer attempt to compile this pipeline again
}