feat(stats): add --stats flag and PipelineStats windowed diagnostics

Add lightweight per-second pipeline statistics for stutter diagnosis:
- --stats CLI flag enables structured stats logging
- PipelineStats tracks capture/encode/send timing with p95/pmax
- FrameTimings records import/scale/transfer/sws/encode per-frame
- StatsSnapshot produces one structured log line per second
This commit is contained in:
dailz
2026-06-07 16:54:45 +08:00
parent f3da1e4e6c
commit 029fe13e37
4 changed files with 498 additions and 0 deletions
+4
View File
@@ -50,4 +50,8 @@ pub struct Args {
/// Force re-authorization dialog (ignore saved portal restore token)
#[arg(long)]
pub no_persist: bool,
/// Enable per-second pipeline statistics output for stutter diagnosis
#[arg(long)]
pub stats: bool,
}