Docs: reflect Phase D2/D3 landing
Archive D2 (view shell) and D3 (persist slice) to COMPLETED.md; add view/view_tree to CLAUDE.md architecture + view_tree_tests target.
This commit is contained in:
@@ -22,7 +22,7 @@ Vendors two submodules (see `.gitmodules`):
|
|||||||
cmake --build build
|
cmake --build build
|
||||||
ctest --test-dir build
|
ctest --test-dir build
|
||||||
|
|
||||||
Five targets:
|
Six targets:
|
||||||
|
|
||||||
| Target | Kind | Purpose |
|
| Target | Kind | Purpose |
|
||||||
|---|---|---|
|
|---|---|---|
|
||||||
@@ -30,6 +30,7 @@ Five targets:
|
|||||||
| `peaks_tests` | executable | Pure unit tests for `peaks` — no REAPER, no DAW. |
|
| `peaks_tests` | executable | Pure unit tests for `peaks` — no REAPER, no DAW. |
|
||||||
| `capture_paths_tests` | executable | Pure unit tests for `capture_paths` — no REAPER, no DAW. |
|
| `capture_paths_tests` | executable | Pure unit tests for `capture_paths` — no REAPER, no DAW. |
|
||||||
| `view_mode_model_tests` | executable | Pure unit tests for `view_mode_model` — no REAPER, no DAW. |
|
| `view_mode_model_tests` | executable | Pure unit tests for `view_mode_model` — no REAPER, no DAW. |
|
||||||
|
| `view_tree_tests` | executable | Pure unit tests for `view_tree` — no REAPER, no DAW. |
|
||||||
| `reaper_reasampler` | loadable module | The actual extension binary (`.dll` / `.dylib` / `.so`). |
|
| `reaper_reasampler` | loadable module | The actual extension binary (`.dll` / `.dylib` / `.so`). |
|
||||||
|
|
||||||
### macOS / Linux: SWELL dialog resources
|
### macOS / Linux: SWELL dialog resources
|
||||||
@@ -50,12 +51,14 @@ There is no hot-reload. Copy the built binary into REAPER's `UserPlugins/` folde
|
|||||||
- `bank_model` — `Sample` metadata struct + `BankIndex` (add/remove/query/tier/dedup-by-hash + JSON round-trip). Test it hard — it is the heart.
|
- `bank_model` — `Sample` metadata struct + `BankIndex` (add/remove/query/tier/dedup-by-hash + JSON round-trip). Test it hard — it is the heart.
|
||||||
- `peaks` — waveform min/max bin computation from raw PCM. Fed a known signal, asserts envelope. Does not depend on REAPER's peak API.
|
- `peaks` — waveform min/max bin computation from raw PCM. Fed a known signal, asserts envelope. Does not depend on REAPER's peak API.
|
||||||
- `view_mode_model` — Design View mode system: mode registry, GUID-keyed membership, folder-tree-aware visibility derivation, snapshot-based park/restore planner, JSON round-trip. Mirror of `bank_model` for the Design View phase.
|
- `view_mode_model` — Design View mode system: mode registry, GUID-keyed membership, folder-tree-aware visibility derivation, snapshot-based park/restore planner, JSON round-trip. Mirror of `bank_model` for the Design View phase.
|
||||||
|
- `view_tree` — pure `I_FOLDERDEPTH`→FolderTree helper for the Design View shell; no REAPER types at the boundary.
|
||||||
|
|
||||||
**REAPER-facing shells:**
|
**REAPER-facing shells:**
|
||||||
- `capture` — `ICaptureBackend` interface; `OfflineRenderBackend` (deterministic default) and `RealtimeRecordBackend`. Input: `CaptureRequest`. Output: finished file + populated `Sample` handed to `bank_model`.
|
- `capture` — `ICaptureBackend` interface; `OfflineRenderBackend` (deterministic default) and `RealtimeRecordBackend`. Input: `CaptureRequest`. Output: finished file + populated `Sample` handed to `bank_model`.
|
||||||
- `insert` — placement via `InsertMedia`; conform-to-project-tempo is an explicit opt-in flag, never silent stretching.
|
- `insert` — placement via `InsertMedia`; conform-to-project-tempo is an explicit opt-in flag, never silent stretching.
|
||||||
- `bank_panel` — docked LICE-drawn grid: thumbnails, audition, multi-select, keyboard navigation.
|
- `bank_panel` — docked LICE-drawn grid: thumbnails, audition, multi-select, keyboard navigation.
|
||||||
- `persist` — project ext state (`SetProjExtState` / `GetProjExtState`, namespace `"reasampler"`) ↔ `bank_model` JSON; project-relative path resolution.
|
- `persist` — project ext state (`SetProjExtState` / `GetProjExtState`, namespace `"reasampler"`) ↔ `bank_model` JSON + `ViewModeModel` JSON (`"view_state"` key); project-relative path resolution.
|
||||||
|
- `view` — Design View shell: reads the folder tree via `view_tree`, snapshots flag values before parking, drives hide + CPU-park on inactive-mode leaves (`B_SHOWINTCP`/`B_SHOWINMIXER`/`B_MAINSEND`/`I_FXEN` + per-FX offline) and derived visibility on parents; restores from snapshot. Never touches master or `B_MUTE`/`I_SOLO`.
|
||||||
- `actions` — registers the capture/placement/slot action family and routes each to the modules above.
|
- `actions` — registers the capture/placement/slot action family and routes each to the modules above.
|
||||||
|
|
||||||
## REAPER extension contract (src/main.cpp)
|
## REAPER extension contract (src/main.cpp)
|
||||||
|
|||||||
@@ -141,3 +141,37 @@ mode.
|
|||||||
- [x] Tests: N-mode add/query; parent follows tagged leaf (multi-mode parent);
|
- [x] Tests: N-mode add/query; parent follows tagged leaf (multi-mode parent);
|
||||||
restore-round-trip returns snapshot values (never hardcoded "on"); show-both leaf
|
restore-round-trip returns snapshot values (never hardcoded "on"); show-both leaf
|
||||||
never parked; unknown/stale GUID tolerated; JSON lossless.
|
never parked; unknown/stale GUID tolerated; JSON lossless.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## D2 — view shell (apply flags in the DAW)
|
||||||
|
**Goal:** Read the folder tree and drive REAPER flags per the planner.
|
||||||
|
CONTEXT.md §Design View (view shell, REAPER API surface).
|
||||||
|
**Verify (in DAW):** Toggling active mode hides + parks inactive leaves
|
||||||
|
(`B_SHOWINTCP`/`B_SHOWINMIXER`/`B_MAINSEND`/`I_FXEN` + per-FX offline) and restores
|
||||||
|
active ones from snapshot. **Master untouched. `B_MUTE`/`I_SOLO` untouched.**
|
||||||
|
Untagged tracks untouched. Parents follow their tagged descendants.
|
||||||
|
|
||||||
|
- [x] Build parent↔child tree from `I_FOLDERDEPTH`; feed to `view_mode_model`.
|
||||||
|
- [x] Snapshot prior flag values (`GetMediaTrackInfo_Value`) before parking.
|
||||||
|
- [x] Apply park/restore ops (`SetMediaTrackInfo_Value` for the four flags;
|
||||||
|
`TrackFX_GetCount` + per-FX `TrackFX_SetOffline`). Verify flag names/signatures.
|
||||||
|
- [x] GUID resolution: `GetTrackGUID` / `guidToString` / `stringToGuid` (never index).
|
||||||
|
- [x] Review gate: no path touches master visibility or `B_MUTE`/`I_SOLO`, or any
|
||||||
|
untagged track's owned flags.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## D3 — persist slice (view state ↔ project ext state)
|
||||||
|
**Goal:** Serialize the view section into the `"reasampler"` namespace alongside the
|
||||||
|
bank; reapply the active mode on project open. CONTEXT.md §Design View (persist).
|
||||||
|
**Verify (in DAW):** Membership + active mode + snapshots survive Save / Save As /
|
||||||
|
close+reopen; on open, the active mode's visibility + processing is reapplied.
|
||||||
|
Saved-while-parked project restores parked tracks from persisted snapshots (not to a
|
||||||
|
guessed "on").
|
||||||
|
|
||||||
|
- [x] Serialize/deserialize the view section under `"reasampler"` (shared blob,
|
||||||
|
distinct section from the bank index).
|
||||||
|
- [x] Reapply active mode on project open (rebuild tree, run the planner).
|
||||||
|
- [x] Confirm survival across Save / Save As; snapshot durability across
|
||||||
|
save-while-parked.
|
||||||
|
|||||||
@@ -127,36 +127,6 @@ landed milestone.
|
|||||||
> spec: **CONTEXT.md §Design View**. Product framing: `docs/product/design-view.md`.
|
> spec: **CONTEXT.md §Design View**. Product framing: `docs/product/design-view.md`.
|
||||||
> When a point lands, doc-keeper moves it to `COMPLETED.md`.
|
> When a point lands, doc-keeper moves it to `COMPLETED.md`.
|
||||||
|
|
||||||
## D2 — view shell (apply flags in the DAW)
|
|
||||||
**Goal:** Read the folder tree and drive REAPER flags per the planner.
|
|
||||||
CONTEXT.md §Design View (view shell, REAPER API surface).
|
|
||||||
**Verify (in DAW):** Toggling active mode hides + parks inactive leaves
|
|
||||||
(`B_SHOWINTCP`/`B_SHOWINMIXER`/`B_MAINSEND`/`I_FXEN` + per-FX offline) and restores
|
|
||||||
active ones from snapshot. **Master untouched. `B_MUTE`/`I_SOLO` untouched.**
|
|
||||||
Untagged tracks untouched. Parents follow their tagged descendants.
|
|
||||||
|
|
||||||
- [ ] Build parent↔child tree from `I_FOLDERDEPTH`; feed to `view_mode_model`.
|
|
||||||
- [ ] Snapshot prior flag values (`GetMediaTrackInfo_Value`) before parking.
|
|
||||||
- [ ] Apply park/restore ops (`SetMediaTrackInfo_Value` for the four flags;
|
|
||||||
`TrackFX_GetCount` + per-FX `TrackFX_SetOffline`). Verify flag names/signatures.
|
|
||||||
- [ ] GUID resolution: `GetTrackGUID` / `guidToString` / `stringToGuid` (never index).
|
|
||||||
- [ ] Review gate: no path touches master visibility or `B_MUTE`/`I_SOLO`, or any
|
|
||||||
untagged track's owned flags.
|
|
||||||
|
|
||||||
## D3 — persist slice (view state ↔ project ext state)
|
|
||||||
**Goal:** Serialize the view section into the `"reasampler"` namespace alongside the
|
|
||||||
bank; reapply the active mode on project open. CONTEXT.md §Design View (persist).
|
|
||||||
**Verify (in DAW):** Membership + active mode + snapshots survive Save / Save As /
|
|
||||||
close+reopen; on open, the active mode's visibility + processing is reapplied.
|
|
||||||
Saved-while-parked project restores parked tracks from persisted snapshots (not to a
|
|
||||||
guessed "on").
|
|
||||||
|
|
||||||
- [ ] Serialize/deserialize the view section under `"reasampler"` (shared blob,
|
|
||||||
distinct section from the bank index).
|
|
||||||
- [ ] Reapply active mode on project open (rebuild tree, run the planner).
|
|
||||||
- [ ] Confirm survival across Save / Save As; snapshot durability across
|
|
||||||
save-while-parked.
|
|
||||||
|
|
||||||
## D4 — actions
|
## D4 — actions
|
||||||
**Goal:** Bindable action set for the mode workflow. CONTEXT.md §Design View
|
**Goal:** Bindable action set for the mode workflow. CONTEXT.md §Design View
|
||||||
(actions). **Verify (in DAW):** Each action registered (bindable in Actions list);
|
(actions). **Verify (in DAW):** Each action registered (bindable in Actions list);
|
||||||
|
|||||||
Reference in New Issue
Block a user