INNER CODE UNIT · Rust
warm_recording_font
free-explorers/veshell · src/embedder/backend/render/mod.rs:533
pub fn warm_recording_font() {
let _ = recording_font();
}
/// Rasterizes the counter text with the fontconfig-resolved family
/// Flutter itself uses, onto a full-chip-sized canvas with the text
/// right-aligned and vertically centered inside it; returns
/// premultiplied BGRA with the coverage in every channel (a white pixel
/// whose alpha is the coverage), or None when the glyph lookup fails.
fn recording_counter_bitmap(
chip: &crate::capture::RecordingChipData,
scale: f64,
) -> Option<(Vec<u8>, Size<i32, Buffer>)> {
let font = recording_font()?;
let seconds = chip.seconds.min(99 * 60 + 59);
let text = format!("{}:{:02}", seconds / 60, seconds % 60);