3.6 KiB
HANDOFF — Session State
Branch / Commit State
main, dirty working tree being committed as one unit (web source rendering fix — user-confirmed
working). NOT pushed — user rule: never push without explicit instruction (2026-08-24). No feature
branches pre-1.0: all work lands on main per work unit.
The web-source rendering work (2026-08-28) — CURRENT MODEL: viewport == element box
Background: the fixed-viewport fix (1920×1080 control + Stretch="Uniform") made the page
render without truncation but left dead space between the selection box and the content (box
aspect ≠ capture aspect → letterbox; box is sized by the parent layout, capture is a separate
hardcoded viewport — they bind to different rects). A CSS-reset experiment made the gap worse
and was shelved by the creator. He stressed the systems must be GEOMETRY-AGNOSTIC: no 16:9,
no fixed render size, no per-widget assumptions.
The model that delivers it (implemented, needs visual verification):
Services/WebView2Manager.cs— the WebView2 viewport IS the element box (Source.Width × Source.Height). The page renders at exactly the box size; aPropertyChangedhook keeps the viewport locked to the box (re-triggers capture on resize, sub-0.5px drift is ignored).CaptureFrameis unchanged (aspect-preserving Physical-size capture).MainWindow.xaml— web<Image>usesStretch="Fill"(capture aspect == box aspect by construction, so Fill == Uniform with zero dead space; during a transient stale frame it just holds aspect briefly). Everything else stillUniformToFill.- Selection rect == content rect by construction → flush edges, no padding, works for any widget
geometry the creator throws at it. FramePump still reads
GetLatestFrameviaResolveOutputFrame. - Transparent-background JS injection retained (background only — no layout/CSS-reset meddling).
Build: 0 warnings; WebView2Manager tests 4/4 (size tracks source, sub-pixel drift ignored, minimum 1, transparent bg).
Landmines (earlier attempts — do not repeat): fixed-viewport (letterbox dead space),
CSS reset/margin juggling (enlarged the gap), control-tracking-box combined with
UniformToFill display (truncation), ZoomFactor meddling. The working invariant is:
viewport rect == selection rect, display = Fill.
Key facts / landmines
- App running locks
ytLive.exe→ build fails MSB3027 until creator exits the app. - Startup diagnostics: unhandled exceptions + checkpoints go to
%APPDATA%\ytLlive\startup.log(Helpers/AppLog.cs). On a silent startup crash, read that. - Pre-existing test failures (unrelated to web source, do not chase):
AudioPipelineTests.Mix_HonorsProviderGains_AndGameMute_KillsTheLoopback+RoundClipInteractionTests.Round_Clip_Corner_Is_Grabbable_And_Shape_Is_Circle. - Real-MainWindow tests MUST set
LayoutPathOverride— DB pollution wiped real data once. - Good Dog Rule: ONE integration test per change; no new feature branches pre-1.0.
- Scope Lock: declare the file list, run
scripts/scope-check.shbefore every commit. - Every feature change ships memory updates in the SAME commit —
TASKS.mdstatus + this file. - No
CODING.md; conventions live inAGENTS.md+ai.md.
Next steps
- AWAIT creator's verdict on viewport==box (geometry-agnostic) rendering — visual check with a widget URL at several box sizes; the selection frame must snap flush with no padding.
- Follow-up only if the creator asks: graceful handling of navigation errors / invalid URIs (TASK 17 ×9).
- Continue queue: TASK 18 local recording, TASK 21 media source, TASK 22 audio sync offset.