From 7217a99dc28184defc529f1c55932b3a43502517 Mon Sep 17 00:00:00 2001 From: Bartosz Taudul Date: Sat, 22 Jun 2019 22:48:32 +0200 Subject: [PATCH] Always show at least one pixel of a frame in frame overview. --- server/TracyView.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server/TracyView.cpp b/server/TracyView.cpp index de343631..c3658b39 100644 --- a/server/TracyView.cpp +++ b/server/TracyView.cpp @@ -1036,7 +1036,7 @@ void View::DrawFrames() } } - const auto h = float( std::min( MaxFrameTime, f ) ) / MaxFrameTime * ( Height - 2 ); + const auto h = std::max( 1.f, float( std::min( MaxFrameTime, f ) ) / MaxFrameTime * ( Height - 2 ) ); if( fwidth != 1 ) { draw->AddRectFilled( wpos + ImVec2( 1 + i*fwidth, Height-1-h ), wpos + ImVec2( fwidth + i*fwidth, Height-1 ), GetFrameColor( f ) );