Skip to main content

overlay

Function overlay 

Source
pub fn overlay(
    path: &str,
    device: &Device,
    queue: &Queue,
    format: TextureFormat,
    gilrs: Option<Gilrs>,
) -> PaneOverlay
Expand description

Create a PaneOverlay that renders into your existing wgpu surface.

  • path — path to the root .ron layout file, relative to the working directory.
  • device / queue — your wgpu device and queue. Pane stores Arc clones of these for hot-reload and per-frame rendering.
  • format — the texture format of your swap chain surface.
  • gilrs — optional pre-constructed gilrs instance for gamepad input.

§Panics

Panics if the .ron file cannot be read or parsed, or if the built-in textured shader is missing from the shader registry.