From abdbaed7377c8eb3c2799ab2b65926253ca8687f Mon Sep 17 00:00:00 2001 From: Martijn Courteaux Date: Tue, 21 May 2024 19:32:43 +0200 Subject: [PATCH] Simplify time comparing display. --- profiler/src/profiler/TracyView_Compare.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/profiler/src/profiler/TracyView_Compare.cpp b/profiler/src/profiler/TracyView_Compare.cpp index 2e0eaac6..f6f1c779 100644 --- a/profiler/src/profiler/TracyView_Compare.cpp +++ b/profiler/src/profiler/TracyView_Compare.cpp @@ -207,10 +207,8 @@ static void PrintSpeedupOrSlowdown( double time_this, double time_external, cons ImGui::SameLine(); ImGui::Spacing(); ImGui::SameLine(); - char buf[128]; - sprintf(buf, "(this %s %c%s is %.2f%% of external %s %c%s)", - ICON_FA_LEMON, tolower( metric[0] ), metric + 1, factor * 100, - ICON_FA_GEM, tolower( metric[0] ), metric + 1 ); + char buf[64]; + sprintf(buf, "(%s = %.2f%% %s)", ICON_FA_LEMON, factor * 100, ICON_FA_GEM ); TextDisabledUnformatted( buf ); }