mirror of
https://github.com/wolfpld/tracy
synced 2025-04-29 12:23:53 +00:00
Add data transferred display to capture utility.
This commit is contained in:
parent
dda192985a
commit
f1fe2df780
@ -117,6 +117,7 @@ int main( int argc, char** argv )
|
|||||||
lock.lock();
|
lock.lock();
|
||||||
const auto mbps = worker.GetMbpsData().back();
|
const auto mbps = worker.GetMbpsData().back();
|
||||||
const auto compRatio = worker.GetCompRatio();
|
const auto compRatio = worker.GetCompRatio();
|
||||||
|
const auto netTotal = worker.GetDataTransferred();
|
||||||
lock.unlock();
|
lock.unlock();
|
||||||
|
|
||||||
if( mbps < 0.1f )
|
if( mbps < 0.1f )
|
||||||
@ -127,7 +128,12 @@ int main( int argc, char** argv )
|
|||||||
{
|
{
|
||||||
printf( "\33[2K\r\033[36;1m%7.2f Mbps", mbps );
|
printf( "\33[2K\r\033[36;1m%7.2f Mbps", mbps );
|
||||||
}
|
}
|
||||||
printf( " \033[0m /\033[36;1m%5.1f%% \033[0m=\033[33;1m%7.2f Mbps \033[0m| Mem: \033[31;1m%.2f MB\033[0m | \033[33mTime: %s\033[0m", compRatio * 100.f, mbps / compRatio, tracy::memUsage.load( std::memory_order_relaxed ) / ( 1024.f * 1024.f ), tracy::TimeToString( worker.GetLastTime() ) );
|
printf( " \033[0m /\033[36;1m%5.1f%% \033[0m=\033[33;1m%7.2f Mbps \033[0m| \033[33mNet: \033[32m%s \033[0m| \033[33mMem: \033[31;1m%.2f MB\033[0m | \033[33mTime: %s\033[0m",
|
||||||
|
compRatio * 100.f,
|
||||||
|
mbps / compRatio,
|
||||||
|
tracy::MemSizeToString( netTotal ),
|
||||||
|
tracy::memUsage.load( std::memory_order_relaxed ) / ( 1024.f * 1024.f ),
|
||||||
|
tracy::TimeToString( worker.GetLastTime() ) );
|
||||||
fflush( stdout );
|
fflush( stdout );
|
||||||
|
|
||||||
std::this_thread::sleep_for( std::chrono::milliseconds( 100 ) );
|
std::this_thread::sleep_for( std::chrono::milliseconds( 100 ) );
|
||||||
|
Loading…
x
Reference in New Issue
Block a user