From 52e3ae719d73c021bf1880dc1ab726be040da993 Mon Sep 17 00:00:00 2001 From: Bartosz Taudul Date: Thu, 27 Apr 2023 17:36:11 +0200 Subject: [PATCH] Remove missed plot vector sorting during draw. --- server/TracyView_Plots.cpp | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/server/TracyView_Plots.cpp b/server/TracyView_Plots.cpp index b3cd8cd1..09a48c28 100644 --- a/server/TracyView_Plots.cpp +++ b/server/TracyView_Plots.cpp @@ -16,10 +16,6 @@ constexpr int PlotHeightPx = 100; bool View::DrawPlot( const TimelineContext& ctx, PlotData& plot, const std::vector& plotDraw, int& offset ) { - auto& vec = plot.data; - vec.ensure_sorted(); - if( vec.front().time.Val() > m_vd.zvEnd || vec.back().time.Val() < m_vd.zvStart ) return false; - auto draw = ImGui::GetWindowDrawList(); const auto& wpos = ctx.wpos; const auto dpos = wpos + ImVec2( 0.5f, 0.5f ); @@ -75,6 +71,7 @@ bool View::DrawPlot( const TimelineContext& ctx, PlotData& plot, const std::vect bool first = true; while( it < end ) { + auto& vec = plot.data; const auto cnt = *it++; const auto i0 = *it++; const auto& v0 = vec[i0];