From 0f0c16f25f2275a6fd491f4b13b3dba3815bcca1 Mon Sep 17 00:00:00 2001 From: "Unknown W. Brackets" Date: Fri, 3 Jul 2015 12:06:17 -0700 Subject: [PATCH] Skip "timing" categories in graph. --- UI/DevScreens.cpp | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/UI/DevScreens.cpp b/UI/DevScreens.cpp index 623f990692..a6f7102636 100644 --- a/UI/DevScreens.cpp +++ b/UI/DevScreens.cpp @@ -815,6 +815,10 @@ void DrawProfile(UIContext &ui) { float legendWidth = 80.0f; for (int i = 0; i < numCategories; i++) { const char *name = Profiler_GetCategoryName(i); + if (!strcmp(name, "timing")) { + continue; + } + float w = 0.0f, h = 0.0f; ui.MeasureText(ui.GetFontStyle(), name, &w, &h); if (w > legendWidth) { @@ -832,6 +836,9 @@ void DrawProfile(UIContext &ui) { for (int i = 0; i < numCategories; i++) { const char *name = Profiler_GetCategoryName(i); + if (!strcmp(name, "timing")) { + continue; + } uint32_t color = nice_colors[i % ARRAY_SIZE(nice_colors)]; float y = legendStartY + i * rowH; @@ -877,6 +884,10 @@ void DrawProfile(UIContext &ui) { maxVal = 0.0f; float maxTotal = 0.0f; for (int i = 0; i < numCategories; i++) { + const char *name = Profiler_GetCategoryName(i); + if (!strcmp(name, "timing")) { + continue; + } Profiler_GetHistory(i, &history[0], historyLength); float x = 10;