aboutsummaryrefslogtreecommitdiff
path: root/src/backend
diff options
context:
space:
mode:
authorIvan Molodetskikh <yalterz@gmail.com>2023-11-24 09:19:49 +0400
committerIvan Molodetskikh <yalterz@gmail.com>2023-11-24 09:19:49 +0400
commit42bb79d7c3c4c9c006226c53167976ec78ae2c94 (patch)
treea9142580bea6c41326e695cb50e17b9d1fef99a2 /src/backend
parent588e6d7cdd3e5226b726f428b545042813f92b3a (diff)
downloadniri-42bb79d7c3c4c9c006226c53167976ec78ae2c94.tar.gz
niri-42bb79d7c3c4c9c006226c53167976ec78ae2c94.tar.bz2
niri-42bb79d7c3c4c9c006226c53167976ec78ae2c94.zip
tty: Rename vblank offset plot to time since presentation
Makes it clearer what this is.
Diffstat (limited to 'src/backend')
-rw-r--r--src/backend/tty.rs24
1 files changed, 13 insertions, 11 deletions
diff --git a/src/backend/tty.rs b/src/backend/tty.rs
index 2ea1e36f..bf579051 100644
--- a/src/backend/tty.rs
+++ b/src/backend/tty.rs
@@ -92,8 +92,8 @@ struct Surface {
vblank_frame: Option<tracy_client::Frame>,
/// Frame name for the VBlank frame.
vblank_frame_name: tracy_client::FrameName,
- /// Plot name for the VBlank dispatch offset plot.
- vblank_plot_name: tracy_client::PlotName,
+ /// Plot name for the time since presentation plot.
+ time_since_presentation_plot_name: tracy_client::PlotName,
/// Plot name for the presentation misprediction plot.
presentation_misprediction_plot_name: tracy_client::PlotName,
sequence_delta_plot_name: tracy_client::PlotName,
@@ -586,8 +586,8 @@ impl Tty {
let vblank_frame_name =
tracy_client::FrameName::new_leak(format!("vblank on {output_name}"));
- let vblank_plot_name =
- tracy_client::PlotName::new_leak(format!("{output_name} vblank dispatch offset, ms"));
+ let time_since_presentation_plot_name =
+ tracy_client::PlotName::new_leak(format!("{output_name} time since presentation, ms"));
let presentation_misprediction_plot_name = tracy_client::PlotName::new_leak(format!(
"{output_name} presentation misprediction, ms"
));
@@ -605,7 +605,7 @@ impl Tty {
dmabuf_feedback,
vblank_frame: None,
vblank_frame_name,
- vblank_plot_name,
+ time_since_presentation_plot_name,
presentation_misprediction_plot_name,
sequence_delta_plot_name,
};
@@ -694,15 +694,17 @@ impl Tty {
format!("vblank on {name}, presentation time unknown")
} else if presentation_time > now {
let diff = presentation_time - now;
- tracy_client::Client::running()
- .unwrap()
- .plot(surface.vblank_plot_name, -diff.as_secs_f64() * 1000.);
+ tracy_client::Client::running().unwrap().plot(
+ surface.time_since_presentation_plot_name,
+ -diff.as_secs_f64() * 1000.,
+ );
format!("vblank on {name}, presentation is {diff:?} later")
} else {
let diff = now - presentation_time;
- tracy_client::Client::running()
- .unwrap()
- .plot(surface.vblank_plot_name, diff.as_secs_f64() * 1000.);
+ tracy_client::Client::running().unwrap().plot(
+ surface.time_since_presentation_plot_name,
+ diff.as_secs_f64() * 1000.,
+ );
format!("vblank on {name}, presentation was {diff:?} ago")
};
tracy_client::Client::running()