Repository navigation
Conversation
A hovered glass card copied the whole canvas into the layer frame, then that frame into the window, and composited the root frame in full, on every frame. The layer frame is now kept: only the dirty tiles and the regions the layers and the jobs after them touched, this frame or the last, are copied and drawn again, and only those reach the window. When the layer goes, the window takes back the regions it covered instead of the whole canvas. The first layer's blur is redone only when its key, the primitives under its box or a tile under it change, and the root frame is composited only while an overlay's backdrop reads it. Hovering a glass card for 120 frames presents 70 152 of 378 400 pixels a frame at 100 % and 157 509 of 851 400 at 150 %, against all of them.
A window buffer only holds the last frame at softbuffer age 1; Wayland swaps two, so at age 2 a partial copy left the old card's glass behind. Any other age now gets every pixel. The first layer's blur fingerprint summed its primitives' hashes, so two overlapping shapes that swapped kept the old blur. It now folds them in paint order.
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 37 minutes. View limit details
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. |
|
Hovering a glass card now updates only the regions that changed instead of copying the whole window on every frame. The window buffer is reused when it still holds the previous frame, and the blurred background work is skipped when no overlay needs it. The picture shown stays the same. No comments posted: the reviewers raised no finding. Review details
Files skipped (1)
Commands run (11)Ran x1-x6 discovery (repo layout, Cargo members, soft tests: a_hovered_glass_card_presents_only_what_changed, swapped_window_buffers_keep_no_old_card, vendor a_still_layer_copies_only_what_changed) and x7-x10 toolchain checks: cargo/rustc absent, no /opt or cargo dirs, curl+python available, /tmp 16G, /work 2.3G free. x11 downloaded rustup.sh but budget expired before installing Rust, so no build, no cargo test, and no app exercise were run. No failures reproduced. passed · exit 0 · 0 s ls -R | head -n 100; echo "---"; cat package.json 2>/dev/null | head -n 80; echo "---"; cat crates/accshift-egui/Cargo.toml 2>/dev/null | head -n 60; echo "---"; git log --oneline -5; echo "---"; git diff --stat HEAD~1 2>/dev/null || git diff --stat origin/main 2>/dev/null || git status --short | head -n 30passed · exit 0 · 0 s cat README.md | head -n 120; echo "==="; cat .github/CONTRIBUTING.md 2>/dev/null | head -n 150; echo "==="; cat scripts/gates.mjs 2>/dev/null | head -n 150passed · exit 0 · 0 s git diff --stat HEAD~1 2>/dev/null || git diff --stat HEAD 2>/dev/null || git log --stat -1 --oneline | head -n 50; echo "==="; git show --stat HEAD | head -n 40passed · exit 0 · 0 s git diff --stat 1891f4e55707c6c7274ef890f249e0b76a0d96d4..HEAD | head -n 30
echo "==="
git log --oneline 1891f4e..HEAD | head -n 20passed · exit 0 · 0 s ls crates/accshift-egui/src/soft/; echo "==="; cat crates/accshift-egui/Cargo.toml | head -n 80
echo "==="; ls crates/accshift-egui/vendor/egui_software_backend/
echo "==="; cat Cargo.toml | head -n 60passed · exit 0 · 0 s grep -n "^fn \|^pub fn \|#\[test\]\|fn a_" crates/accshift-egui/src/soft/tests.rs | head -n 60
echo "==="
grep -n "#\[test\]\|fn a_\|fn test" crates/accshift-egui/vendor/egui_software_backend/src/lib.rs | head -n 60failed · exit 127 · 0 s cargo test -p accshift-egui --lib soft::tests::a_hovered_glass_card_presents_only_what_changed -- --nocapture --test-threads=1 2>&1 | tail -n 60failed · exit 1 · 0 s ls ~/.cargo/bin/ 2>&1; echo "==="; ls /usr/local/cargo/bin/ 2>&1; echo "==="; which rustc 2>&1; ls /opt/ 2>&1; echo "==="; find / -maxdepth 5 -name cargo -type f 2>/dev/null | headfailed · exit 1 · 0 s echo $PATH; echo "==="; ls /usr/local/bin/ 2>&1 | head -n 50; echo "==="; ls / | head -n 30; echo "==="; find / -maxdepth 6 -name "cargo" 2>/dev/null | head -n 20failed · exit 2 · 0 s cat /etc/os-release; echo "==="; curl --version 2>&1 | head -n 3; wget --version 2>&1 | head -n 3; python3 --version 2>&1; echo "==="; df -h 2>&1 | head; echo "==="; env | grep -i -E "home|cargo|rust" 2>&1; echo "==="; ls -la /work/.patrol-home/ 2>&1 | head -n 20passed · exit 0 · 0 s mkdir -p /work/.patrol-home && df -h /work /tmp 2>&1 | head; echo "==="; curl -sSf https://sh.rustup.rs -o /tmp/rustup.sh && ls -lh /tmp/rustup.sh && head -n 5 /tmp/rustup.sh |
Note
Clanker Claude Opus 5.5 is responding on behalf of meetsu
Summary
Hovering a card in Glass Dark no longer copies the whole window every frame: the glass layer keeps its frame between frames and only the tiles that changed reach the window, with no visible change.
what changed
compose_backdropkeeps the layer frame, recopies only dirty tiles and the areas a layer touched this frame or the previous one, and presents only that damage (vendor/egui_software_backend/src/lib.rs).blur_fingerprint,dirty_under).compose_filteris incremental while the filtered input stays the same.keep_root_frame,soft/paint.rs).to question
CPU time per hover frame does not move: rasterizing dominates, the copies were small next to it. The gain is the bytes handed to the window each frame (-81 %), which the compositor no longer takes in whole.
verified
mainfor noise: max MAE 0.622 vs 0.874 noise, worst 16x16 tile 20.71 vs 20.71. The 35 card-hover captures are identical to the pixel. 7 captures exceed their own noise by 1 level on a few text edges:list-glass-dark-150has no glass layer andmainproduces the same variant under load;armed-glass-dark-150renders identical when run alone;onboarding-dealpersist-error matches the main-vs-main gap (27 levels).a_hovered_glass_card_presents_only_what_changedfails onmain(a still hover presented 378400 of 378400 pixels) and passes 6 of 6 after; it compares each partial window to a fresh full render. Vendor testa_still_layer_copies_only_what_changedpasses (window equals a fresh render, blur not rerun for a hover outside the box, window restored when the layer leaves).mainalready does in 1 run of 6, so the test allows 2 levels per channel.build-safe node scripts/gates.mjspassed 7/7 gates on Windows, including 407 egui and 22 software renderer tests.Related issue
None.
Tested on
Checklist