17
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-10-28 16:57:29 +01:00

perf(debug): count what wakes the physics of the vehicles (brake pipe, main reservoir pipe, command, speed, acceleration, neighbour, other) in the debug panel

This commit is contained in:
2026-10-23 19:08:09 +02:00
parent f17462b186
commit 9a7ff372f7
4 changed files with 42 additions and 11 deletions

View File

@@ -883,7 +883,15 @@ void opengl46_renderer::SwapBuffers()
3,
"switching per second: compressor on " + std::to_string( switching.events[ source::compressor_on ] ) + ", off "
+ std::to_string( switching.events[ source::compressor_off ] ) + ", mains " + std::to_string( switching.events[ source::mains ] ) + ", diesel "
+ std::to_string( switching.events[ source::diesel ] ) + ", physics woken " + std::to_string( switching.events[ source::wake ] ),
+ std::to_string( switching.events[ source::diesel ] ),
"" );
text += timeline(
3,
"physics woken per second: brake pipe " + std::to_string( switching.events[ source::wake_mainpipe ] ) + ", main reservoir pipe "
+ std::to_string( switching.events[ source::wake_scndpipe ] ) + ", command " + std::to_string( switching.events[ source::wake_command ] )
+ ", speed " + std::to_string( switching.events[ source::wake_speed ] ) + ", acceleration "
+ std::to_string( switching.events[ source::wake_acceleration ] ) + ", neighbour " + std::to_string( switching.events[ source::wake_neighbour ] )
+ ", cab/ezt " + std::to_string( switching.events[ source::wake_rest ] ) + ", other " + std::to_string( switching.events[ source::wake ] ),
"" );
if( switching.busiestevents > 0 ) {
text += timeline( 3, "most often: " + switching.busiest + " (" + std::to_string( switching.busiestevents ) + ")", "" );