diff options
author | Bartosz Taudul <wolf.pld@gmail.com> | 2019-08-13 04:28:18 +0300 |
---|---|---|
committer | Bartosz Taudul <wolf.pld@gmail.com> | 2019-08-13 16:16:46 +0300 |
commit | d77c87ae1c6826e3d6ee1c1b2d32b07c1094a792 (patch) | |
tree | 9682b90bdae04dd5c5f8b8aab9dc038028598e7e /server/TracyView.cpp | |
parent | 874a2596f7308818415cf432ebc4b47c3c151bfc (diff) |
Allow disabling context switch drawing.
Diffstat (limited to 'server/TracyView.cpp')
-rw-r--r-- | server/TracyView.cpp | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/server/TracyView.cpp b/server/TracyView.cpp index 8f47a8da..2141d6f6 100644 --- a/server/TracyView.cpp +++ b/server/TracyView.cpp @@ -1883,11 +1883,14 @@ void View::DrawZones() offset += ostep; if( showFull ) { - auto ctxSwitch = m_worker.GetContextSwitchData( v->id ); - if( ctxSwitch ) + if( m_drawContextSwitches ) { - DrawContextSwitches( ctxSwitch, pxns, int64_t( nspx ), wpos, offset ); - offset += round( ostep * 0.75f ); + auto ctxSwitch = m_worker.GetContextSwitchData( v->id ); + if( ctxSwitch ) + { + DrawContextSwitches( ctxSwitch, pxns, int64_t( nspx ), wpos, offset ); + offset += round( ostep * 0.75f ); + } } if( m_drawZones ) @@ -5345,6 +5348,11 @@ void View::DrawOptions() #else ImGui::Checkbox( "Draw empty labels", &m_drawEmptyLabels ); #endif +#ifdef TRACY_EXTENDED_FONT + ImGui::Checkbox( ICON_FA_HIKING " Draw context switches", &m_drawContextSwitches ); +#else + ImGui::Checkbox( "Draw context switches", &m_drawContextSwitches ); +#endif ImGui::Separator(); const auto& gpuData = m_worker.GetGpuData(); |