Files
LlamaCasty/TASKS/task-35-scene-linked-audio.md
T
gramps c257de1516 feat(35): scenes remember the room — BRB mutes the mic on entry
591 green, 0 warnings.

- `Scene.SceneMutesMic` / `SceneMutesDesktop` are **nullable booleans**: null = leave the mix alone, so
  a scene is passive until the creator says otherwise. Schema columns added, NULL for every existing
  layout except one deliberate default.
- **Applied once when the scene takes the PROGRAM output** (`TransitionToScene`, only when live or
  recording). Staging a scene offline is auditioning, not a stream edit — the test asserts that.
- **The creator is boss:** a manual mute survives any transition into a scene with no opinion; a scene
  that does have one wins on its next entry. `SetMicMuted`/`SetGameMuted` are idempotent so a repeated
  "mute" cannot clobber the level that unmute would restore.
- **BRB ships muted** (creator spec) for new layouts *and* via a one-time migration for existing rows
  where the creator has never expressed an opinion.
- UI: two three-state checkboxes under the layers list ("When this scene goes live"), styled with
  `PropertyPillCheck` so the theme test holds.

`SceneAudioTests` covers the whole rule in one integration test: default state, offline staging does
nothing, live entry mutes, manual unmute survives a passive scene, an opinionated scene wins, desktop
untouched, and all three states roundtrip through save/reload.

Needs the creator's eye: the checkboxes are new chrome in the left panel (indeterminate = passive).
2026-11-10 11:51:21 -08:00

26 lines
1.6 KiB
Markdown

# TASK 35 — Scene-linked audio: "scenes remember the room" (queued 2026-09-01; spec approved by the creator same day)
> Catalog: [`TASKS.md`](../TASKS.md) — status and requirements live here.
**Goal:** the BRB scene mutes the mic; the Chat scene brings it back. The creator stops fiddling with
audio at transitions — the scene carries the room state. OBS needs scripts/plugins; native = the
creator-proof pitch.
**Shipped 2026-11-10.** Columns `Scene.SceneMutesMic` / `SceneMutesDesktop` (nullable = passive),
three-state checkboxes under the layers list ("When this scene goes live"), applied once at the program
transition in `TransitionToScene`. `SceneAudioTests` pins the whole rule: offline staging edits nothing,
`null` never overrides a manual mute, a scene with an opinion wins on its next entry, and all three
states survive a save/reload.
1. ✅ `Scene` gains nullable `SceneMutesMic` / `SceneMutesDesktop` — `null` = don't touch (the default;
scenes are passive until told). Schema column bump + roundtrip.
2. ✅ Applied on **live transitions only** (thumbnail click / hotkey), ONCE at entry — never on
offline staging (no surprise stream-state edits while auditioning).
3. ✅ The creator is boss: a manual mute/unmute mid-scene is never overridden until the next entry.
4. ✅ BRB ships `SceneMutesMic = true`; other scenes default `null` — creator's choice.
5. ✅ Edit UI: two checkboxes in the scene's Properties section (left panel, edit mode) — no new chrome.
6. ✅ Test (the ONE): transition applies scene state; `null` leaves state untouched; manual override
survives until the next entry.