struct ViewportRepaintInfo {
cumulative_frame_nr: u64,
cumulative_pass_nr: u64,
repaint_delay: Duration,
outstanding: u8,
causes: Vec<RepaintCause>,
prev_causes: Vec<RepaintCause>,
prev_pass_paint_delay: Duration,
}
Expand description
Per-viewport state related to repaint scheduling.
Fields§
§cumulative_frame_nr: u64
Monotonically increasing counter.
Incremented at the end of Context::run
.
This can be smaller than Self::cumulative_pass_nr
,
but never larger.
cumulative_pass_nr: u64
Monotonically increasing counter, counting the number of passes.
This can be larger than Self::cumulative_frame_nr
,
but never smaller.
repaint_delay: Duration
The duration which the backend will poll for new events before forcing another egui update, even if there’s no new events.
Also used to suppress multiple calls to the repaint callback during the same pass.
This is also returned in crate::ViewportOutput
.
outstanding: u8
While positive, keep requesting repaints. Decrement at the start of each pass.
causes: Vec<RepaintCause>
What caused repaints during this pass?
prev_causes: Vec<RepaintCause>
What triggered a repaint the previous pass? (i.e: why are we updating now?)
prev_pass_paint_delay: Duration
What was the output of repaint_delay
on the previous pass?
If this was zero, we are repainting as quickly as possible (as far as we know).