mirror of
https://github.com/eliasstepanik/strudel-docker.git
synced 2026-01-11 13:48:34 +00:00
* 0.5 default cps * 1 -> 0.5 cps defaults * start moving examples to 2Hz * more 2Hz doc edits * small tweaks * format * adapt cycles page * adapt pitch page * tonal page * accumulation * synth page * adapt conditional-modifiers * audio effects page * adapt signals doc * fix: errors for signals * adapt signals page * start time modifiers * adapt time modifiers * adapt factories * hydra + pattern intro * adapt mini notation page * start recipes * adapt recipes page * use code_v1 table * delete old dbdump + add new csv based tool * fix: tests * fix: cpm * shuffle featured patterns * fix: snapshot --------- Co-authored-by: Felix Roos <flix91@gmail.com>
@strudel/tonal
This package adds tonal / harmonic functions to strudel Patterns.
Install
npm i @strudel/tonal --save
Example
import { sequence } from '@strudel/core';
import '@strudel/tonal';
const pattern = sequence(0, [1, 2]).scale('C major');
const events = pattern.firstCycle().map((e) => e.show());
yields:
(0/1 -> 1/2, 0/1 -> 1/2, C3)
(1/2 -> 3/4, 1/2 -> 3/4, D3)
(3/4 -> 1/1, 3/4 -> 1/1, E3)
play with @strudel/tonal codesandbox
Tonal API
See "Tonal API" in the Strudel Tutorial