Skip to main content

install_render_app

Function install_render_app 

Source
pub fn install_render_app(
    app: &mut App,
    ctx: &WgpuContext,
    width: u32,
    height: u32,
    oit_layers: usize,
    setup: RenderSetup,
)
Expand description

Build and install the render sub-app for app, with the project’s RenderSetup applied.

On every [App::update], right after the main schedule ran, the sub-app’s extract hook swaps the main world’s current EvaluatedFrame into the render world (the render world’s previous batch storage moves back, so both sides keep reusing their allocations).

§Panics

Panics if a plugin is not ready after installation. This supports synchronous setup using the already initialized GPU context.