refactor(app): unify overlay rendering on LayerRenderer #964

Merged
SakulFlee merged 1 commit from refactor/overlay-layers into main 2026-10-28 23:26:08 +00:00
Owner

Summary

Removes the parallel legacy overlay API and unifies all overlays on LayerRenderer.

  • Adds OverlaySubmission::{MainEncoder, Owned} to LayerRenderer.
  • Main-encoder layers record into the scene submission; owned-submission layers run afterwards. Iced remains Owned until its fork exposes an encoder.
  • Ports the 2D shape overlays, debug render overlay, and touch joystick to LayerRenderer with World2D, UI, and Debug layers.
  • Removes the RenderOverlay trait, RenderOverlayResource::overlays, RenderOverlayResource::add, and the legacy parameter from Module::register_overlays.
  • Renames the frame stage to STAGE_OVERLAY_MAIN and documents the submission-order caveat.
  • This is an intentional pre-1.6 API break for external overlay implementations.

Depends on #963; the PR targets perf/renderer-overlay-submit and should be retargeted to main after #963 merges.

Validation

  • cargo test --workspace --no-fail-fast passes.
  • cargo check --workspace with the workspace clippy driver and -D warnings passes.
  • Rust formatting checks pass across Crates/ and Examples/.
  • Visual verification still needs a display/GPU machine; this environment cannot render a frame.
## Summary Removes the parallel legacy overlay API and unifies all overlays on `LayerRenderer`. - Adds `OverlaySubmission::{MainEncoder, Owned}` to `LayerRenderer`. - Main-encoder layers record into the scene submission; owned-submission layers run afterwards. Iced remains `Owned` until its fork exposes an encoder. - Ports the 2D shape overlays, debug render overlay, and touch joystick to `LayerRenderer` with `World2D`, `UI`, and `Debug` layers. - Removes the `RenderOverlay` trait, `RenderOverlayResource::overlays`, `RenderOverlayResource::add`, and the legacy parameter from `Module::register_overlays`. - Renames the frame stage to `STAGE_OVERLAY_MAIN` and documents the submission-order caveat. - This is an intentional pre-1.6 API break for external overlay implementations. Depends on #963; the PR targets `perf/renderer-overlay-submit` and should be retargeted to `main` after #963 merges. ## Validation - `cargo test --workspace --no-fail-fast` passes. - `cargo check --workspace` with the workspace clippy driver and `-D warnings` passes. - Rust formatting checks pass across `Crates/` and `Examples/`. - Visual verification still needs a display/GPU machine; this environment cannot render a frame.
refactor(app): unify overlay rendering on LayerRenderer
All checks were successful
Lint / lint (pull_request) Successful in 1m39s
Templates / templates (pull_request) Successful in 4m47s
PR / test (pull_request) Successful in 6m29s
fe83ba41f5

Smart test results

Result: PASS

Scope: orbital_app, orbital_debug_render, orbital_debug_ui, orbital_ecs_bridge, orbital_iced, orbital_touch_ui

Reason: directly changed crates

Elapsed: 5m 56s

Workflow run

Overall: 127 tests, 123 passed, 0 failed, 4 skipped

Nextest: 123 tests, 123 passed, 0 failed, 0 skipped
Doctests: 4 tests, 0 passed, 0 failed, 4 skipped

Outcome charts are split between nextest and doctests. The timing chart covers nextest only.

Crate Nextest Passed Failed Skipped Doctests Time
orbital_app 10 10 0 0 0/1 0.07s
orbital_debug_render 0 0 0 0 0/1 0.00s
orbital_debug_ui 45 45 0 0 0/1 0.32s
orbital_ecs_bridge 42 42 0 0 - 0.35s
orbital_iced 25 25 0 0 - 0.18s
orbital_touch_ui 1 1 0 0 0/1 0.01s
pie showData
    title Nextest outcomes
    "Passed" : 123
pie showData
    title Doctest outcomes
    "Skipped" : 4
xychart-beta
    title "Slowest crates (nextest seconds)"
    x-axis ["orbital_ecs_bridge", "orbital_debug_ui", "orbital_iced", "orbital_app", "orbital_touch_ui"]
    y-axis "Seconds" 0 --> 1
    bar [0.35, 0.32, 0.18, 0.07, 0.01]
<!-- orbital-ci-test-results --> ## Smart test results **Result:** PASS **Scope:** orbital_app, orbital_debug_render, orbital_debug_ui, orbital_ecs_bridge, orbital_iced, orbital_touch_ui **Reason:** directly changed crates **Elapsed:** 5m 56s [Workflow run](https://forgejo.sakul-flee.de/SakulFlee/Orbital/actions/runs/818) **Overall:** 127 tests, 123 passed, 0 failed, 4 skipped **Nextest:** 123 tests, 123 passed, 0 failed, 0 skipped **Doctests:** 4 tests, 0 passed, 0 failed, 4 skipped _Outcome charts are split between nextest and doctests. The timing chart covers nextest only._ | Crate | Nextest | Passed | Failed | Skipped | Doctests | Time | | --- | ---: | ---: | ---: | ---: | ---: | ---: | | orbital_app | 10 | 10 | 0 | 0 | 0/1 | 0.07s | | orbital_debug_render | 0 | 0 | 0 | 0 | 0/1 | 0.00s | | orbital_debug_ui | 45 | 45 | 0 | 0 | 0/1 | 0.32s | | orbital_ecs_bridge | 42 | 42 | 0 | 0 | - | 0.35s | | orbital_iced | 25 | 25 | 0 | 0 | - | 0.18s | | orbital_touch_ui | 1 | 1 | 0 | 0 | 0/1 | 0.01s | ```mermaid pie showData title Nextest outcomes "Passed" : 123 ``` ```mermaid pie showData title Doctest outcomes "Skipped" : 4 ``` ```mermaid xychart-beta title "Slowest crates (nextest seconds)" x-axis ["orbital_ecs_bridge", "orbital_debug_ui", "orbital_iced", "orbital_app", "orbital_touch_ui"] y-axis "Seconds" 0 --> 1 bar [0.35, 0.32, 0.18, 0.07, 0.01] ```
SakulFlee changed target branch from perf/renderer-overlay-submit to main 2026-10-28 23:25:54 +00:00
SakulFlee deleted branch refactor/overlay-layers 2026-10-28 23:26:08 +00:00
Sign in to join this conversation.
No description provided.