mirror of
https://github.com/wolfpld/tracy.git
synced 2024-11-27 00:04:35 +00:00
Use separate texture compression context for saving traces.
This commit is contained in:
parent
c2dd3913d7
commit
db9557fc84
@ -7001,15 +7001,18 @@ void Worker::Write( FileWrite& f )
|
|||||||
f.Write( &sz, sizeof( sz ) );
|
f.Write( &sz, sizeof( sz ) );
|
||||||
if( sz != 0 ) f.Write( m_data.appInfo.data(), sizeof( m_data.appInfo[0] ) * sz );
|
if( sz != 0 ) f.Write( m_data.appInfo.data(), sizeof( m_data.appInfo[0] ) * sz );
|
||||||
|
|
||||||
sz = m_data.frameImage.size();
|
|
||||||
f.Write( &sz, sizeof( sz ) );
|
|
||||||
for( auto& fi : m_data.frameImage )
|
|
||||||
{
|
{
|
||||||
f.Write( &fi->w, sizeof( fi->w ) );
|
TextureCompression texcomp;
|
||||||
f.Write( &fi->h, sizeof( fi->h ) );
|
sz = m_data.frameImage.size();
|
||||||
f.Write( &fi->flip, sizeof( fi->flip ) );
|
f.Write( &sz, sizeof( sz ) );
|
||||||
const auto image = m_texcomp.Unpack( *fi );
|
for( auto& fi : m_data.frameImage )
|
||||||
f.Write( image, fi->w * fi->h / 2 );
|
{
|
||||||
|
f.Write( &fi->w, sizeof( fi->w ) );
|
||||||
|
f.Write( &fi->h, sizeof( fi->h ) );
|
||||||
|
f.Write( &fi->flip, sizeof( fi->flip ) );
|
||||||
|
const auto image = texcomp.Unpack( *fi );
|
||||||
|
f.Write( image, fi->w * fi->h / 2 );
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Only save context switches relevant to active threads.
|
// Only save context switches relevant to active threads.
|
||||||
|
Loading…
Reference in New Issue
Block a user