Feat: overhaul to produce .dmg and .app on macOS build script

This commit is contained in:
2026-02-28 03:15:51 +01:00
parent 7ae3f255b0
commit 81fb174d7e
6 changed files with 136 additions and 1 deletions

View File

@@ -45,6 +45,8 @@ snare sound 0.5 speed . ( play snare at half speed )
| `n` | 0+ | Sample index within a folder (wraps around) |
| `begin` | 0-1 | Playback start position |
| `end` | 0-1 | Playback end position |
| `slice` | 1+ | Divide sample into N equal slices |
| `pick` | 0+ | Select which slice to play (0-indexed, wraps) |
| `speed` | any | Playback speed multiplier |
| `freq` | Hz | Base frequency for pitch tracking |
| `fit` | seconds | Stretch/compress sample to fit duration |
@@ -62,6 +64,21 @@ kick sound 0.5 end . ( play first half )
If begin is greater than end, they swap automatically.
## Slice and Pick
For evenly-spaced slicing, `slice` divides the sample into N equal parts and `pick` selects which one (0-indexed, wraps around).
```forth
break sound 8 slice 3 pick . ( play the 4th eighth of the sample )
break sound 16 slice step pick . ( scan through 16 slices by step )
```
Combine with `fit` to time-stretch each slice to a target duration. `fit` accounts for the sliced range automatically.
```forth
break sound 4 slice 2 pick 1 loop . ( quarter of the sample, fitted to 1 beat )
```
## Speed and Pitch
The `speed` parameter affects both tempo and pitch. A speed of 2 plays twice as fast and an octave higher.