Skip to content

Listen to a pattern through its samples - #22

Merged
JarlLyng merged 1 commit into
mainfrom
step-audition
Oct 20, 2026
Merged

JarlLyng merged 1 commit into
mainfrom
step-audition

Conversation

@JarlLyng

Copy link
Copy Markdown
Owner

Lets you hear a pattern through its loaded samples before it goes to the card, and hear a single step by clicking it.

What it does

  • Play / Stop next to Tempo, or Space. ⇧Space plays from the cursor's row. The pattern loops, the row being heard is highlighted, and edits, tempo changes and a switch of pattern are picked up while it plays.
  • Click a step to hear it (the cursor moves there too). Click a row number to hear the whole row. A typed note sounds as it goes in.
  • With no samples loaded, the status line says there is nothing to hear yet.
  • Help > Keyboard Shortcuts has a new Listening section.

What it plays

A preview, not the Tracker's sound engine. PreviewRenderer (new, in PatternautCore/Playback) plays notes and their instruments, OFF / FAD / CUT, and the Volume, Chance, Micro-move, Panning, Tune, Micro-tune and Reverse effects. Each instrument's volume, panning, tune, finetune and start/end points apply. Tracks play one note at a time, and a note without an instrument plays 00, the way the card stores it.

Not heard: filters, sends, LFOs, slides, glide, rolls, arps, random effects, gate length, overdrive, bit depth, loops, slices, granular. MIDI and synth instruments are silent.

Two choices worth checking against a Tracker:

  • Root note. A sample plays at its own pitch on raw note 60. The Tracker shows that note as C5 (its manual's percussion walkthrough: "Set to C5, the root note for the sample"). Patternaut shows the same note as C4.
  • Micro-move. The manual calls the shift small without saying how small, so 100 is taken as half a step.

How it is built

  • Timing runs on whole frames from the top of the pattern, so a note lands on the same frame however the audio is split into blocks. A test checks this by rendering in mixed block sizes against one long render.
  • The app renders blocks of 2048 frames on a queue of its own. It keeps four queued ahead, so an edit is heard within about a fifth of a second. Audio output is released after twenty idle seconds.
  • No new entitlements; audio output needs none.

Checked

  • swift test: 156 tests pass, 16 of them new for the renderer (pitch, timing, volume, Chance, note-offs, takeover, loop, block boundaries, Micro-move, panning, tune, reverse, click audition, .pti decoding).
  • The app builds with no new warnings. With a test document (a synthesised kick and hat), Space starts and stops playback, the highlighted row moves and wraps at the end, and Core Audio reports the app running output while it plays and not once it has been idle. With no samples, the hint shows.
  • Not checked: mouse clicks (macOS would not let the test script click) and the sound by ear.

Before a release

  • The README and the site still say the app has no audio engine. They describe the shipped app, so they change when this ships.
  • Generated beats put drums on raw notes 36, 38 and 42 and the bass from 24. If the root is 60, the Tracker plays those two or more octaves below the samples' own pitch, and so does this preview. Worth one test on the hardware before deciding whether the generator should move to 60.

🤖 Generated with Claude Code

Play (Space, or Shift-Space from the cursor's row) loops the pattern on
screen through the loaded samples and highlights the row being heard. It
follows edits, tempo and a pattern switch while it plays. Clicking a step
plays it, clicking a row number plays the row, and typed notes sound as
they go in.

The sound comes from PreviewRenderer in the core: notes, instruments,
OFF/FAD/CUT and the Volume, Chance, Micro-move, Panning, Tune, Micro-tune
and Reverse effects, through each instrument's volume, panning, tuning,
start and end points. A sample plays at its own pitch on raw note 60, the
Tracker's C5. Timing runs on whole frames, so block size never moves a
note. MIDI and synth instruments stay silent, and so do the effects the
preview does not model. The app renders blocks on a queue of its own and
lets go of audio output after twenty idle seconds.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@JarlLyng
JarlLyng merged commit 80d7772 into main Oct 20, 2026
2 checks passed
@JarlLyng
JarlLyng deleted the step-audition branch October 20, 2026 10:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant