mirror of
https://github.com/wolfpld/tracy.git
synced 2024-11-27 00:04:35 +00:00
Allow getting zone color sans higlights, etc.
This commit is contained in:
parent
6ef282dd1a
commit
b7522ec4c1
@ -11827,10 +11827,15 @@ uint32_t View::GetZoneColor( const ZoneEvent& ev )
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
return GetRawZoneColor( ev );
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
uint32_t View::GetRawZoneColor( const ZoneEvent& ev )
|
||||||
|
{
|
||||||
const auto& srcloc = m_worker.GetSourceLocation( ev.SrcLoc() );
|
const auto& srcloc = m_worker.GetSourceLocation( ev.SrcLoc() );
|
||||||
const auto color = srcloc.color;
|
const auto color = srcloc.color;
|
||||||
return color != 0 ? ( color | 0xFF000000 ) : 0xFFCC5555;
|
return color != 0 ? ( color | 0xFF000000 ) : 0xFFCC5555;
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
uint32_t View::GetZoneColor( const GpuEvent& ev )
|
uint32_t View::GetZoneColor( const GpuEvent& ev )
|
||||||
@ -11840,6 +11845,11 @@ uint32_t View::GetZoneColor( const GpuEvent& ev )
|
|||||||
return color != 0 ? ( color | 0xFF000000 ) : 0xFF222288;
|
return color != 0 ? ( color | 0xFF000000 ) : 0xFF222288;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
uint32_t View::GetRawZoneColor( const GpuEvent& ev )
|
||||||
|
{
|
||||||
|
return GetZoneColor( ev );
|
||||||
|
}
|
||||||
|
|
||||||
uint32_t View::GetZoneHighlight( const ZoneEvent& ev )
|
uint32_t View::GetZoneHighlight( const ZoneEvent& ev )
|
||||||
{
|
{
|
||||||
if( m_zoneInfoWindow == &ev )
|
if( m_zoneInfoWindow == &ev )
|
||||||
|
@ -156,6 +156,8 @@ private:
|
|||||||
|
|
||||||
uint32_t GetZoneColor( const ZoneEvent& ev );
|
uint32_t GetZoneColor( const ZoneEvent& ev );
|
||||||
uint32_t GetZoneColor( const GpuEvent& ev );
|
uint32_t GetZoneColor( const GpuEvent& ev );
|
||||||
|
uint32_t GetRawZoneColor( const ZoneEvent& ev );
|
||||||
|
uint32_t GetRawZoneColor( const GpuEvent& ev );
|
||||||
uint32_t GetZoneHighlight( const ZoneEvent& ev );
|
uint32_t GetZoneHighlight( const ZoneEvent& ev );
|
||||||
uint32_t GetZoneHighlight( const GpuEvent& ev );
|
uint32_t GetZoneHighlight( const GpuEvent& ev );
|
||||||
float GetZoneThickness( const ZoneEvent& ev );
|
float GetZoneThickness( const ZoneEvent& ev );
|
||||||
|
Loading…
Reference in New Issue
Block a user