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

Fix message color component names in the protocol.

Red and blue channels were mislabeled. Otherwise, coding and decoding was
performed correctly, as far as the color channel order described in the manual
is followed by the user.

No change to the binary protocol was made.
This commit is contained in:
Bartosz Taudul
2023-01-23 01:07:07 +01:00
parent c59413ab56
commit eb7c13e7bb
3 changed files with 8 additions and 8 deletions
+2 -2
View File
@@ -5625,7 +5625,7 @@ void Worker::ProcessMessageColor( const QueueMessageColor& ev )
msg->time = time;
msg->ref = StringRef( StringRef::Type::Idx, GetSingleStringIdx() );
msg->thread = CompressThread( td->id );
msg->color = 0xFF000000 | ( ev.r << 16 ) | ( ev.g << 8 ) | ev.b;
msg->color = 0xFF000000 | ( ev.b << 16 ) | ( ev.g << 8 ) | ev.r;
msg->callstack.SetVal( 0 );
if( m_data.lastTime < time ) m_data.lastTime = time;
InsertMessageData( msg );
@@ -5640,7 +5640,7 @@ void Worker::ProcessMessageLiteralColor( const QueueMessageColorLiteral& ev )
msg->time = time;
msg->ref = StringRef( StringRef::Type::Ptr, ev.text );
msg->thread = CompressThread( td->id );
msg->color = 0xFF000000 | ( ev.r << 16 ) | ( ev.g << 8 ) | ev.b;
msg->color = 0xFF000000 | ( ev.b << 16 ) | ( ev.g << 8 ) | ev.r;
msg->callstack.SetVal( 0 );
if( m_data.lastTime < time ) m_data.lastTime = time;
InsertMessageData( msg );