Merge branch 'main' into 48-superdough-features
This commit is contained in:
@ -39,7 +39,7 @@
|
||||
"tone": "^14.8.49",
|
||||
"unique-names-generator": "^4.7.1",
|
||||
"vite-plugin-markdown": "^2.1.0",
|
||||
"zifferjs": "^0.0.21",
|
||||
"zifferjs": "^0.0.24",
|
||||
"zzfx": "^1.2.0"
|
||||
}
|
||||
}
|
||||
|
||||
@ -199,6 +199,20 @@ export class Player extends Event {
|
||||
return this;
|
||||
}
|
||||
|
||||
voiceleading() {
|
||||
if (this.atTheBeginning()) this.ziffers.lead();
|
||||
return this;
|
||||
}
|
||||
|
||||
lead = () => this.voiceleading();
|
||||
|
||||
invert = (n: number) => {
|
||||
if (this.atTheBeginning()) {
|
||||
this.ziffers.invert(n);
|
||||
}
|
||||
return this;
|
||||
}
|
||||
|
||||
retrograde() {
|
||||
if (this.atTheBeginning()) this.ziffers.retrograde();
|
||||
return this;
|
||||
|
||||
@ -28,6 +28,7 @@ The basic Ziffer notation is entirely written in JavaScript strings (_e.g_ <ic>"
|
||||
| **Accidentals** | <ic># b</ic> | Sharp and flats, just like with regular music notation :smile: |
|
||||
| **Rest** | <ic>r</ic> | Rest / silences |
|
||||
| **Repeat** | <ic>:1-9</ic> | Repeat the item 1-9 times |
|
||||
| **Chords** | <ic>[1-9]+ / [iv]+ / [AG]+name</ic> | Multiple pitches grouped together, roman numerals or named chords |
|
||||
|
||||
**Note:** Some features are still unsupported. For full syntax see article about <a href="https://zenodo.org/record/7841945" target="_blank">Ziffers</a>.
|
||||
|
||||
@ -136,6 +137,29 @@ ${makeExample(
|
||||
`
|
||||
)}
|
||||
|
||||
${makeExample(
|
||||
"Chord transposition with roman numerals",
|
||||
`
|
||||
z1('i i v%-4 v%-2 vi%-5 vi%-3 iv%-2 iv%-1').sound('sawtooth').out()
|
||||
`
|
||||
)}
|
||||
|
||||
${makeExample(
|
||||
"Chord transposition with named chords",
|
||||
`
|
||||
z1('e C9:4 Emin:4 F7%-1:4 Emaj%-1:4')
|
||||
.sound("stab").out()
|
||||
`
|
||||
)}
|
||||
|
||||
${makeExample(
|
||||
"Programmatic inversions",
|
||||
`
|
||||
z1('i v vi iv').invert([1,-1,-2,0].beat(4))
|
||||
.sound("sawtooth").out()
|
||||
`
|
||||
)}
|
||||
|
||||
## Algorithmic operations
|
||||
|
||||
Ziffers provides shorthands for **many** numeric and algorithimic operations such as evaluating random numbers and creating sequences using list operations:
|
||||
|
||||
@ -1451,10 +1451,10 @@ yaml@^2.1.1:
|
||||
resolved "https://registry.yarnpkg.com/yaml/-/yaml-2.3.1.tgz#02fe0975d23cd441242aa7204e09fc28ac2ac33b"
|
||||
integrity sha512-2eHWfjaoXgTBC2jNM1LRef62VQa0umtvRiDSk6HSzW7RvS5YtkabJrwYLLEKWBc8a5U2PTSCs+dJjUTJdlHsWQ==
|
||||
|
||||
zifferjs@^0.0.21:
|
||||
version "0.0.21"
|
||||
resolved "https://registry.yarnpkg.com/zifferjs/-/zifferjs-0.0.21.tgz#5df0c6541ae189b2515b4eb4856eb9d2c0610778"
|
||||
integrity sha512-wJat1nbeCJ1j7+5YpeB5MnZdbyFfAwVRB8Ei+cgViEtjidwe4oCLtNq1p8Gq1PjjpSzr32YR57egCdME2Lb5qg==
|
||||
zifferjs@^0.0.24:
|
||||
version "0.0.24"
|
||||
resolved "https://registry.yarnpkg.com/zifferjs/-/zifferjs-0.0.24.tgz#073f606086ed7977a8c5cd6cc2f9d6c897415281"
|
||||
integrity sha512-pTUM2i3pTBsINiflBym48pzQnEmw93Xf9GVq0FUnnWwLBirwJJsOxJeZZG/c7DVf4EnV7oC1Ik/R5ULt2sVtug==
|
||||
|
||||
zzfx@^1.2.0:
|
||||
version "1.2.0"
|
||||
|
||||
Reference in New Issue
Block a user