pub struct MessageDef {}Expand description
One pre-authored text overlay.
Fields§
§slot: u321-based slot index from the section header ([message01]).
Slot 0 is reserved.
text: StringDisplay string. Bytes are taken verbatim from the INI; the renderer is responsible for picking glyphs (the bundled Ubuntu-Light covers Basic Latin + Latin-1 Supplement).
font: u32Font slot index (0..15). MD2 lets the user pre-load 16
fonts; OneDrop’s MVP renderer always uses Ubuntu-Light
(slot 0) so non-zero indices currently fall back to the
default. Kept as parsed for forward-compat.
size: f32Point size of the text in pixels. MD2 measured in pixels rather than typographic points; we keep that convention.
x: f32Centre x / y in normalised [0, 1] screen coords (top-left
origin). The renderer turns these into clip-space transforms.
y: f32§r: u8Colour in 0..255 (we keep u8 rather than f32 since the
INI surface is integer-valued).
g: u8§b: u8§bold: boolStyle flags. bold and italic are advisory in the MVP
renderer (Ubuntu-Light is regular weight only); kept for the
future font-pack work.
italic: bool§fade_in_s: f32Animation timing in seconds.
fade_out_s: f32§duration_s: f32Time the message stays at full opacity between fade-in and fade-out. Total on-screen time = fade_in + duration + fade_out.
burn: boolburn=1 writes the message once into render_texture on
completion (so it persists through the warp feedback loop)
and then drops it from the active list.
Trait Implementations§
Source§impl Clone for MessageDef
impl Clone for MessageDef
Source§fn clone(&self) -> MessageDef
fn clone(&self) -> MessageDef
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more