Merged
Conversation
Issue: Implement issue #284 by avoiding unnecessary rerasterization when the focused full-screen terminal has not changed. Solution: Route steady-state full-view rendering through the shared cached session path already used for grid rendering. Track whether a cached texture contains only terminal content or content plus overlays so wave effects stay correct while steady-state overlays remain live. Add focused renderer tests for cache reuse and invalidation, and update the architecture docs to describe the new caching behavior.
There was a problem hiding this comment.
Pull request overview
This PR extends Architect’s existing per-session texture caching model so steady-state full-screen terminal rendering can reuse cached content instead of rerasterizing the terminal surface every frame, while keeping overlays live except when wave effects require baking overlays into the cached texture.
Changes:
- Unifies grid and full-view steady-state rendering through a shared cached-session rendering path.
- Tracks cache “composition” (content-only vs content+overlays) to support wave effects without overlay artifacts.
- Updates architecture documentation and adds predicate-level tests for cache refresh decisions.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| src/render/renderer.zig | Introduces cache composition tracking and a shared renderSessionCached path used by both grid tiles and full view; adds tests for refresh predicate logic. |
| docs/ARCHITECTURE.md | Documents that renderer caching now applies to both grid tiles and steady-state full view, and elaborates on epoch-based invalidation. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Issue: Address the unresolved review feedback on PR #288 about full-view cache retention, inaccurate architecture wording, and a misleading test name. Solution: Release unfocused session caches during steady-state full view so Architect does not accumulate full-window textures as focus moves between sessions. Update the architecture text to describe epoch mismatch rather than a less-than check, and rename the predicate-level test so it matches what the test actually verifies.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #284
Summary
This change brings steady-state full-screen rendering onto the same cached-content model Architect already uses for grid tiles. The renderer now reuses a cached full-view terminal texture when the focused session has not changed, while still keeping overlays live unless an active wave effect needs them baked into the cached texture.
Changes
Test plan