1
0
mirror of https://github.com/wolfpld/tracy.git synced 2025-03-20 07:40:02 +08:00

Move vis data to timeline controller.

This commit is contained in:
Bartosz Taudul
2022-08-20 17:02:29 +02:00
parent 49bda91be5
commit 655d8a01ea
10 changed files with 120 additions and 104 deletions
-22
View File
@@ -80,15 +80,6 @@ class View
};
public:
struct VisData
{
bool visible = true;
bool showFull = true;
bool ghost = false;
int offset = 0;
int height = 0;
};
struct PlotView
{
double min;
@@ -330,7 +321,6 @@ private:
void SetPlaybackFrame( uint32_t idx );
bool Save( const char* fn, FileWrite::Compression comp, int zlevel, bool buildDict );
unordered_flat_map<const void*, VisData> m_visData;
unordered_flat_map<uint64_t, bool> m_visibleMsgThread;
unordered_flat_map<uint64_t, bool> m_waitStackThread;
unordered_flat_map<const void*, int> m_gpuDrift;
@@ -338,16 +328,6 @@ private:
Vector<const ThreadData*> m_threadOrder;
Vector<float> m_threadDnd;
tracy_force_inline VisData& Vis( const void* ptr )
{
auto it = m_visData.find( ptr );
if( it == m_visData.end() )
{
it = m_visData.emplace( ptr, VisData {} ).first;
}
return it->second;
}
tracy_force_inline bool& VisibleMsgThread( uint64_t thread )
{
auto it = m_visibleMsgThread.find( thread );
@@ -378,8 +358,6 @@ private:
return it->second;
}
void AdjustThreadHeight( View::VisData& vis, int oldOffset, int& offset );
float AdjustThreadPosition( View::VisData& vis, float wy, int& offset );
static int64_t AdjustGpuTime( int64_t time, int64_t begin, int drift );
static const char* DecodeContextSwitchState( uint8_t state );