Archive Milestone 3 in docs
Move completed M3 (offline capture spike) from PLAN.md to COMPLETED.md; close the render-command and bank-format open questions; add capture_paths_tests to the CLAUDE.md targets table and note M8 is dialog-free.
This commit is contained in:
@@ -4,7 +4,7 @@ This file provides guidance to Claude Code (claude.ai/code) when working with co
|
|||||||
|
|
||||||
## Repo identity and current state
|
## Repo identity and current state
|
||||||
|
|
||||||
The CMake project and binary are now named `reaper_reasampler`. This is **ReaSampler** — a per-project audio sample-bank capture tool. The MPE modules (`mpe_model`, `mpe_view`) have been removed. The pure core (M0–M2) is complete: `bank_model` (Sample metadata + BankIndex with JSON round-trip) and `peaks` (waveform min/max bin computation) are both implemented and fully tested. The REAPER-facing shells (`capture`, `insert`, `bank_panel`, `persist`, `actions`) are being built out per CONTEXT.md / PLAN.md. The *discipline* — pure REAPER-free testable core split from REAPER-facing shells — is **preserved** throughout.
|
The CMake project and binary are now named `reaper_reasampler`. This is **ReaSampler** — a per-project audio sample-bank capture tool. The MPE modules (`mpe_model`, `mpe_view`) have been removed. M0–M3 are complete: `bank_model` (Sample metadata + BankIndex with JSON round-trip), `peaks` (waveform min/max bin computation), and the `capture` shell's offline-render path (DAW-verified spike: master-mix / time-selection capture to a project-relative bank at 32-bit float WAV, non-destructive) are all implemented and tested. The remaining REAPER-facing shells (`insert`, `bank_panel`, `persist`, `actions`) and the realtime backend are being built out per CONTEXT.md / PLAN.md. The *discipline* — pure REAPER-free testable core split from REAPER-facing shells — is **preserved** throughout.
|
||||||
|
|
||||||
CONTEXT.md is the authoritative spec and build roadmap. Read it first for any non-trivial task. Every REAPER API name cited there is correct-by-intent; verify argument order, types, and flag values against `vendor/reaper-sdk/sdk/reaper_plugin_functions.h` before use.
|
CONTEXT.md is the authoritative spec and build roadmap. Read it first for any non-trivial task. Every REAPER API name cited there is correct-by-intent; verify argument order, types, and flag values against `vendor/reaper-sdk/sdk/reaper_plugin_functions.h` before use.
|
||||||
|
|
||||||
@@ -22,12 +22,13 @@ Vendors two submodules (see `.gitmodules`):
|
|||||||
cmake --build build
|
cmake --build build
|
||||||
ctest --test-dir build
|
ctest --test-dir build
|
||||||
|
|
||||||
Three targets:
|
Four targets:
|
||||||
|
|
||||||
| Target | Kind | Purpose |
|
| Target | Kind | Purpose |
|
||||||
|---|---|---|
|
|---|---|---|
|
||||||
| `bank_model_tests` | executable | Pure unit tests for `bank_model` — no REAPER, no DAW. |
|
| `bank_model_tests` | executable | Pure unit tests for `bank_model` — no REAPER, no DAW. |
|
||||||
| `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. |
|
||||||
| `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
|
||||||
|
|||||||
@@ -67,3 +67,31 @@ preserved; bin count honored for arbitrary sample lengths (incl. remainder bin).
|
|||||||
- [x] Multi-channel handling (per-channel envelope; no silent fold).
|
- [x] Multi-channel handling (per-channel envelope; no silent fold).
|
||||||
- [x] Tests: sine envelope ≈ ±amplitude; ramp envelope monotonic; DC/silence →
|
- [x] Tests: sine envelope ≈ ±amplitude; ramp envelope monotonic; DC/silence →
|
||||||
zero envelope; short-buffer and non-divisible-length edge cases.
|
zero envelope; short-buffer and non-divisible-length edge cases.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Milestone 3 — Offline capture spike (REAPER shell)
|
||||||
|
**Goal:** Offline-render the time-selection master mix to a wav in the project
|
||||||
|
bank folder, add a `Sample`, log it. The render-driving spike. CONTEXT.md
|
||||||
|
§REAPER API surface (offline render), Build order 3.
|
||||||
|
**Verify (in DAW):** Render runs via `Main_OnCommand(42230)` ("Render using most
|
||||||
|
recent settings") — REAPER always shows its offline-render progress window; no
|
||||||
|
stock/header-documented fully-headless path exists. File lands in the
|
||||||
|
project-relative bank folder at **32-bit float WAV** at project rate (lossless,
|
||||||
|
dither-free → enables bit-identical/null-test). A `Sample` is added to the
|
||||||
|
in-memory `BankIndex`. Non-destructive. Unsaved-project state triggers a
|
||||||
|
Save-As prompt; capture is refused if the user cancels (no default-location
|
||||||
|
fallback).
|
||||||
|
**Bit-identical repeats:** two identical requests produce byte-identical files.
|
||||||
|
**Exact bounds:** rendered length matches the requested range (no rounding, no
|
||||||
|
added silence without an explicit tail).
|
||||||
|
|
||||||
|
- [x] `ICaptureBackend` interface + `CaptureRequest` (source mode, time range,
|
||||||
|
wet/dry, tail, SR/bit-depth/channels, output path). CONTEXT.md §capture.
|
||||||
|
- [x] `OfflineRenderBackend`: drive `GetSetProjectInfo` render settings +
|
||||||
|
`GetSetProjectInfo_String` file/pattern/format; **verify every flag against
|
||||||
|
`vendor/reaper-sdk/sdk/reaper_plugin_functions.h`.**
|
||||||
|
- [x] Resolve the no-dialog render command/flag on the current REAPER build
|
||||||
|
(open question) and confirm it runs headless.
|
||||||
|
- [x] Populate a `Sample` from the finished file; hand to `bank_model`; console-log.
|
||||||
|
- [x] Verify bit-identical repeats and exact-bounds by hand on a known range.
|
||||||
|
|||||||
@@ -14,26 +14,6 @@ it here and appends it to `COMPLETED.md`.
|
|||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
## Milestone 3 — Offline capture spike (REAPER shell)
|
|
||||||
**Goal:** Offline-render the time-selection master mix to a wav in the project
|
|
||||||
bank folder, add a `Sample`, log it. The render-driving spike. CONTEXT.md
|
|
||||||
§REAPER API surface (offline render), Build order 3.
|
|
||||||
**Verify (in DAW):** Headless (no-dialog) render runs; file lands in the
|
|
||||||
project-relative bank folder; a `Sample` is added to the in-memory `BankIndex`.
|
|
||||||
**Bit-identical repeats:** two identical requests produce byte-identical files.
|
|
||||||
**Exact bounds:** rendered length matches the requested range (no rounding, no
|
|
||||||
added silence without an explicit tail).
|
|
||||||
|
|
||||||
- [ ] `ICaptureBackend` interface + `CaptureRequest` (source mode, time range,
|
|
||||||
wet/dry, tail, SR/bit-depth/channels, output path). CONTEXT.md §capture.
|
|
||||||
- [ ] `OfflineRenderBackend`: drive `GetSetProjectInfo` render settings +
|
|
||||||
`GetSetProjectInfo_String` file/pattern/format; **verify every flag against
|
|
||||||
`vendor/reaper-sdk/sdk/reaper_plugin_functions.h`.**
|
|
||||||
- [ ] Resolve the no-dialog render command/flag on the current REAPER build
|
|
||||||
(open question) and confirm it runs headless.
|
|
||||||
- [ ] Populate a `Sample` from the finished file; hand to `bank_model`; console-log.
|
|
||||||
- [ ] Verify bit-identical repeats and exact-bounds by hand on a known range.
|
|
||||||
|
|
||||||
## Milestone 4 — persist (index ↔ project ext state)
|
## Milestone 4 — persist (index ↔ project ext state)
|
||||||
**Goal:** Write the `BankIndex` JSON to project ext state, reload on project open;
|
**Goal:** Write the `BankIndex` JSON to project ext state, reload on project open;
|
||||||
project-relative path resolution. CONTEXT.md §persist, §Persistence & paths.
|
project-relative path resolution. CONTEXT.md §persist, §Persistence & paths.
|
||||||
@@ -89,6 +69,8 @@ bank entries. CONTEXT.md §capture (realtime), §Precision invariants.
|
|||||||
into the bank; **non-destructive** — temp track removed cleanly, source routing
|
into the bank; **non-destructive** — temp track removed cleanly, source routing
|
||||||
and user monitoring restored unchanged.
|
and user monitoring restored unchanged.
|
||||||
|
|
||||||
|
**Note (from M3):** The realtime backend captures during playback and does NOT invoke the offline-render path, so it is inherently dialog-free (no render-progress window) — a secondary benefit beyond hardware/performed-FX capture.
|
||||||
|
|
||||||
- [ ] Hidden-track resample recipe (`I_RECMODE`/`I_RECINPUT`/`I_RECARM`,
|
- [ ] Hidden-track resample recipe (`I_RECMODE`/`I_RECINPUT`/`I_RECARM`,
|
||||||
`CSurf_OnRecord`/`CSurf_OnStop`); verify record-mode values against SDK.
|
`CSurf_OnRecord`/`CSurf_OnStop`); verify record-mode values against SDK.
|
||||||
- [ ] Resolve wet-master routing that does not alter user monitoring (open
|
- [ ] Resolve wet-master routing that does not alter user monitoring (open
|
||||||
@@ -136,11 +118,8 @@ invariants; drag-out places a valid file in the OS target.
|
|||||||
Carried from CONTEXT.md §Open questions — keep visible until each is closed by a
|
Carried from CONTEXT.md §Open questions — keep visible until each is closed by a
|
||||||
landed milestone.
|
landed milestone.
|
||||||
|
|
||||||
- **No-dialog render command/flag** on the current REAPER build. (blocks M3)
|
|
||||||
- **Realtime wet-master routing** that captures master output without altering the
|
- **Realtime wet-master routing** that captures master output without altering the
|
||||||
user's monitoring. (blocks M8)
|
user's monitoring. (blocks M8)
|
||||||
- **Bank audio format:** wav bit-depth default; allow float for wavetable
|
|
||||||
fidelity. (touches M3, informs M1 `Sample` fields)
|
|
||||||
- **Thumbnail cache:** recompute peaks vs store peak bins alongside the index.
|
- **Thumbnail cache:** recompute peaks vs store peak bins alongside the index.
|
||||||
(touches M2/M4/M5)
|
(touches M2/M4/M5)
|
||||||
- **`parseInt` narrowing hardening:** `src/bank_model.cpp` `parseInt` casts
|
- **`parseInt` narrowing hardening:** `src/bank_model.cpp` `parseInt` casts
|
||||||
|
|||||||
Reference in New Issue
Block a user