mirror of
https://github.com/wolfpld/tracy
synced 2025-04-29 12:23:53 +00:00
Fix color channels names in zone color message.
This commit is contained in:
parent
eb7c13e7bb
commit
6652999a60
@ -4110,9 +4110,9 @@ TRACY_API void ___tracy_emit_zone_color( TracyCZoneCtx ctx, uint32_t color ) {
|
|||||||
#endif
|
#endif
|
||||||
{
|
{
|
||||||
TracyQueuePrepareC( tracy::QueueType::ZoneColor );
|
TracyQueuePrepareC( tracy::QueueType::ZoneColor );
|
||||||
tracy::MemWrite( &item->zoneColor.r, uint8_t( ( color ) & 0xFF ) );
|
tracy::MemWrite( &item->zoneColor.b, uint8_t( ( color ) & 0xFF ) );
|
||||||
tracy::MemWrite( &item->zoneColor.g, uint8_t( ( color >> 8 ) & 0xFF ) );
|
tracy::MemWrite( &item->zoneColor.g, uint8_t( ( color >> 8 ) & 0xFF ) );
|
||||||
tracy::MemWrite( &item->zoneColor.b, uint8_t( ( color >> 16 ) & 0xFF ) );
|
tracy::MemWrite( &item->zoneColor.r, uint8_t( ( color >> 16 ) & 0xFF ) );
|
||||||
TracyQueueCommitC( zoneColorThread );
|
TracyQueueCommitC( zoneColorThread );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -143,9 +143,9 @@ public:
|
|||||||
if( GetProfiler().ConnectionId() != m_connectionId ) return;
|
if( GetProfiler().ConnectionId() != m_connectionId ) return;
|
||||||
#endif
|
#endif
|
||||||
TracyQueuePrepare( QueueType::ZoneColor );
|
TracyQueuePrepare( QueueType::ZoneColor );
|
||||||
MemWrite( &item->zoneColor.r, uint8_t( ( color ) & 0xFF ) );
|
MemWrite( &item->zoneColor.b, uint8_t( ( color ) & 0xFF ) );
|
||||||
MemWrite( &item->zoneColor.g, uint8_t( ( color >> 8 ) & 0xFF ) );
|
MemWrite( &item->zoneColor.g, uint8_t( ( color >> 8 ) & 0xFF ) );
|
||||||
MemWrite( &item->zoneColor.b, uint8_t( ( color >> 16 ) & 0xFF ) );
|
MemWrite( &item->zoneColor.r, uint8_t( ( color >> 16 ) & 0xFF ) );
|
||||||
TracyQueueCommit( zoneColorThread );
|
TracyQueueCommit( zoneColorThread );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -166,9 +166,9 @@ struct QueueZoneValidationThread : public QueueZoneValidation
|
|||||||
|
|
||||||
struct QueueZoneColor
|
struct QueueZoneColor
|
||||||
{
|
{
|
||||||
uint8_t r;
|
|
||||||
uint8_t g;
|
|
||||||
uint8_t b;
|
uint8_t b;
|
||||||
|
uint8_t g;
|
||||||
|
uint8_t r;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct QueueZoneColorThread : public QueueZoneColor
|
struct QueueZoneColorThread : public QueueZoneColor
|
||||||
|
@ -5331,7 +5331,7 @@ void Worker::ProcessZoneColor( const QueueZoneColor& ev )
|
|||||||
auto& stack = td->stack;
|
auto& stack = td->stack;
|
||||||
auto zone = stack.back();
|
auto zone = stack.back();
|
||||||
auto& extra = RequestZoneExtra( *zone );
|
auto& extra = RequestZoneExtra( *zone );
|
||||||
const uint32_t color = ( ev.r << 16 ) | ( ev.g << 8 ) | ev.b;
|
const uint32_t color = ( ev.b << 16 ) | ( ev.g << 8 ) | ev.r;
|
||||||
extra.color = color;
|
extra.color = color;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user