Check rules
What each rule in an oxframe check report means and how to fix it. Every issue in report.json links to its section here in its docs field (Rust code gets
the same link from Issue::docs).
oxframe check plays every scene, samples frames and reports what a viewer would see
as a mistake. An error makes the command exit 1; a warning does not. Each issue names the rule,
the time range, the node and the line of code that added it. Thresholds live in oxframe.toml under [check].
An issue on a node comes with a close-up in out/check/issues/: the frame around the
node at full resolution, the node outlined in red. Its path is the issue's crop field
in report.json, next to bounds, the node's box. A node wholly outside
the frame gets the strip along the edge it went past.
The fix in each issue
Most issues carry fix: the change that clears them, with the numbers worked out, so
neither you nor an agent has to measure the frame. The hint says the same in words.
action | Fields | From |
|---|---|---|
move | dx, dy: pixels, x to the right, y down | out_of_frame, text_overlap |
shrink | width, height: the most that fits | out_of_frame on a node bigger than the frame |
color | color (#rrggbb, the same hue lightened or darkened) and the contrast it reaches | low_contrast over a fill |
widen | by: pixels of extra width, or font_scale for the font size | text_overflow |
hold | seconds the text must stay on screen | too_fast text |
slow | seconds the move should last at least | too_fast motion |
{
"rule": "out_of_frame",
"node": "headline",
"source": "src/main.rs:24",
"hint": "The node reaches outside the frame. Move it 140 px to the left (or make it smaller).",
"fix": { "action": "move", "dx": -140.0, "dy": 0.0 }
} A fix clears the issue it belongs to; it does not know your design. Moving a headline 140 px may
call for moving what sits next to it too, and a smaller font may read better as a shorter line.
Text over a shader or an image has no single color behind it, so its low_contrast issue comes without a color. dead_time and covers_text have no fix: what
to add, or where the shader goes, is a choice. In Rust the field is an Option<lint::Fix> on lint::Issue.
issues/02-out_of_frame.png: a headline that runs off the right edge.Frame and layout
out_of_frame
A node stays outside the frame (error) or outside the safe area near the edges (warning). A node that only passes through the edge, entering or leaving, is not reported.
Fix: move it inward, make it smaller, or place it with pct(), to_edge(Edge::…) or a Layout. --safe-inset 0 turns the warning
off for a frame without a safe area.
text_overflow
Text is wider than its block: its max_width, or the Layout that holds it.
Fix: shorter text, a smaller type style (.h2(), .body()), or a wider
block.
text_overlap
Two pieces of text cover each other.
Fix: place one relative to the other (next_to(other, Side::Bottom)), put both in a Layout, or fade the first out before the second comes in.
covers_text
A shader is drawn over text, so the text is hidden behind it. A shader that reads the frame (lens_drops, or your own with Input::frame()) shows the text through it and is not reported.
Fix: add the shader before the text, or move the text out of its box.
low_contrast
Text is too close in color to what is behind it, below the WCAG ratio (4.5 by default, --min-contrast). Over a plain fill the two colors are compared. Over a shader, an
image, a video, Custom, particles or 3D, check draws the frame without the
text and reads the pixels behind it: the ratio is the median over the text's box, and it must stay low
for 0.5 s, so something moving past a label is not reported.
Fix: use theme roles, which are built to contrast: Text on Background or Surface, OnAccent on Accent.
Timing
too_fast
Text is not on screen long enough to read at the reading speed (--chars-per-second),
or a large move is quicker than --min-motion.
Fix: hold the text with wait_for(…) after it appears, or give the move a longer
duration. In a presentation, hold before each slide_break: the video plays through
it.
dead_time
Nothing changes on screen for longer than --max-still (not checked with a soundtrack).
Fix: shorten the wait, or give the viewer something to look at while it lasts.
Review
review_note
A note a person wrote in the editor under oxframe dev, still open. note_text says what to change; the issue has
the time, the node and its file:line, the marked area and a crop. Always an error.
Fix: do what the note says, then oxframe notes done <id> --reply "what you changed".
Voice
voice_cut
A spoken line runs past the end of its scene and is cut.
Fix: line.await before the scene ends, or shorten the line.
voice_overlap
Two spoken lines overlap.
Fix: start the second line after first.await.
Shaders
shader_error
The WGSL of a shader does not compile, or a name or type does not match its Params.
Fix: the message names the line in the shader; see lesson 13.
param_unknown
A parameter is set from Rust that the shader's Params does not have.
Fix: add it to struct Params or correct the name.
shader_slow
A shader takes longer per frame than the budget.
Fix: a smaller box, fewer loop iterations, or a preset from shaders::.
Determinism and media
nondeterministic
Two paints of the same frame differ, so a seek or a render would not match the preview.
Fix: draw only from signals and ctx.time(); take randomness from ctx.rng(seed), never from the clock or from numbers kept between paints.
video_unavailable
A video clip cannot be opened; it shows as a dark box.
Fix: check the path, build with the video feature and install ffmpeg. The playground cannot
play videos.