Skip to main content Module render Copy item path Source QuadVertex One corner of a rounded-rect quad. The fragment shader reconstructs the box
from rect + border_radius and evaluates a rounded-rect SDF per pixel, so
every vertex of a quad carries identical rect/radius/border data. Renderer build_quads Walk the scene graph and build the draw commands (vertex + index buffers)
for every visible node that paints a background or a border. clear_color Pick the framebuffer clear colour: the root background if it is opaque
enough to matter, else the first child (<body>) that has one, else white. create_quad_pipeline Build the rounded-rect SDF quad pipeline. Split out of Renderer::new so
it can be created against a headless device in tests. create_viewport_bind_group_layout Bind group layout for the viewport uniform consumed by the quad shader. quad_shader_source WGSL source for the rounded-rect SDF quad pipeline. Exposed so tests can
compile it against a headless device.