Add dedicated frame Vsync queue message.

This commit is contained in:
Bartosz Taudul 2022-07-30 19:50:42 +02:00
parent b19f9e1f4d
commit e86238642a
No known key found for this signature in database
GPG Key ID: B7FE2008B7575DF3
2 changed files with 10 additions and 1 deletions

View File

@ -9,7 +9,7 @@ namespace tracy
constexpr unsigned Lz4CompressBound( unsigned isize ) { return isize + ( isize / 255 ) + 16; } constexpr unsigned Lz4CompressBound( unsigned isize ) { return isize + ( isize / 255 ) + 16; }
enum : uint32_t { ProtocolVersion = 59 }; enum : uint32_t { ProtocolVersion = 60 };
enum : uint16_t { BroadcastVersion = 2 }; enum : uint16_t { BroadcastVersion = 2 };
using lz4sz_t = uint32_t; using lz4sz_t = uint32_t;

View File

@ -78,6 +78,7 @@ enum class QueueType : uint8_t
FrameMarkMsg, FrameMarkMsg,
FrameMarkMsgStart, FrameMarkMsgStart,
FrameMarkMsgEnd, FrameMarkMsgEnd,
FrameVsync,
SourceLocation, SourceLocation,
LockAnnounce, LockAnnounce,
LockTerminate, LockTerminate,
@ -196,6 +197,12 @@ struct QueueFrameMark
uint64_t name; // ptr uint64_t name; // ptr
}; };
struct QueueFrameVsync
{
int64_t time;
uint32_t id;
};
struct QueueFrameImage struct QueueFrameImage
{ {
uint32_t frame; uint32_t frame;
@ -670,6 +677,7 @@ struct QueueItem
QueueZoneValueThread zoneValueThread; QueueZoneValueThread zoneValueThread;
QueueStringTransfer stringTransfer; QueueStringTransfer stringTransfer;
QueueFrameMark frameMark; QueueFrameMark frameMark;
QueueFrameVsync frameVsync;
QueueFrameImage frameImage; QueueFrameImage frameImage;
QueueFrameImageFat frameImageFat; QueueFrameImageFat frameImageFat;
QueueSourceLocation srcloc; QueueSourceLocation srcloc;
@ -813,6 +821,7 @@ static constexpr size_t QueueDataSize[] = {
sizeof( QueueHeader ) + sizeof( QueueFrameMark ), // continuous frames sizeof( QueueHeader ) + sizeof( QueueFrameMark ), // continuous frames
sizeof( QueueHeader ) + sizeof( QueueFrameMark ), // start sizeof( QueueHeader ) + sizeof( QueueFrameMark ), // start
sizeof( QueueHeader ) + sizeof( QueueFrameMark ), // end sizeof( QueueHeader ) + sizeof( QueueFrameMark ), // end
sizeof( QueueHeader ) + sizeof( QueueFrameVsync ),
sizeof( QueueHeader ) + sizeof( QueueSourceLocation ), sizeof( QueueHeader ) + sizeof( QueueSourceLocation ),
sizeof( QueueHeader ) + sizeof( QueueLockAnnounce ), sizeof( QueueHeader ) + sizeof( QueueLockAnnounce ),
sizeof( QueueHeader ) + sizeof( QueueLockTerminate ), sizeof( QueueHeader ) + sizeof( QueueLockTerminate ),