From 43dc12ca3934299daa6b87894c9fac997a8f2b4b Mon Sep 17 00:00:00 2001 From: Bartosz Taudul Date: Wed, 20 Sep 2017 22:41:05 +0200 Subject: [PATCH] Select 3 frames, not 2. --- server/TracyView.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/server/TracyView.cpp b/server/TracyView.cpp index 425134c5..44c4d5df 100755 --- a/server/TracyView.cpp +++ b/server/TracyView.cpp @@ -513,7 +513,7 @@ void View::DrawFrames() if( !m_pause ) { m_frameStart = ( total < onScreen * group ) ? 0 : total - onScreen * group; - m_zvStart = m_frames[std::max( 0, (int)m_frames.size() - 3 )]; + m_zvStart = m_frames[std::max( 0, (int)m_frames.size() - 4 )]; m_zvEnd = m_frames.back(); } @@ -601,7 +601,7 @@ void View::DrawFrames() } const auto zitbegin = std::lower_bound( m_frames.begin(), m_frames.end(), m_zvStart ); - const auto zitend = std::upper_bound( m_frames.begin(), m_frames.end(), m_zvEnd ); + const auto zitend = std::lower_bound( m_frames.begin(), m_frames.end(), m_zvEnd ); const auto zbegin = (int)std::distance( m_frames.begin(), zitbegin ); const auto zend = (int)std::distance( m_frames.begin(), zitend );