Releases: ddj231/Handel
Releases · ddj231/Handel
0.5.7
New Features
- bubble's up errors so errors thrown by the RunHandel function are able to be caught.
Note: the RunHandel function now returns a promise.
Example:
The following run of an invalid Handel program would print an error message in the console.
Handel.RunHandel(`
start
*
finish
`).catch((ex) => console.log(ex));
0.5.6
0.5.5
New Features
- Adds variable reassignment. Variables can be reassigned using the
update
keyword. - Adds note shifting functionality. Note shifting is a kind of variable reassignment that shifts a note left or right by a number of semitones.
Examples:
The snippet below plays E5
for 1 beat.
start
save mynote = E4
update mynote = E5
play mynote for 1b
finish
The example program below uses the note shifting functionality and plays a major scale starting at Bb2
.
start
chunk majorscale using startnote
save mynote = startnote
block
play mynote for 1b
update mynote rshift 2
endblock loop for 3
update mynote lshift 1
block
play mynote for 1b
update mynote rshift 2
endblock loop for 4
update mynote lshift 1
play mynote for 1b
endchunk
save startnote = Bb2
run majorscale using startnote with sound piano
finish
v0.5.2
v0.5.0
New Features
- This version adds Notelists as a built in type. Functionally this means playables can now be created with a variable storing a notelist, and a variable storing a duration.
Example:
start
chunk example using somenotelist, someduration
play somenotelist for someduration
endchunk
save mynotelist = E2, G#3, Ab3
save myduration = for 3b
run example using mynotelist, myduration
finish
Bug fixes
- fixes bug causing block loops to be stacked (this made playables played in block loops louder than others).
v0.4.3
0.4.2
0.4.1
0.4.0
New Features
- This version adds the ability to load custom instruments in Handel Programs
The syntax is: load someinstrument as instrumentname
The run of the Handel program must be configured. Below is an example. (See documentation for more details)
let myinst = Handel.MakeInstrument({
A1: 'https://tonejs.github.io/audio/casio/A1.mp3',
A2: 'https://tonejs.github.io/audio/casio/A2.mp3'
})
let config = {}
config.instruments = {funkyinst: myinst}
Handel.RunHandel(`
start
load funkyinst as funky
chunk example
play E4 for 4b
enchunk
run example with sound funky
finish
`, config)
0.3.0
Breaking changes
- Handel (v0.3.0 and up) is now bundled with Webpack. This has caused slight modifications to the install and import of Handel.
- RunHandel and StopHandel are no longer global functions and must be accessed as follows.
Handel.RunHandel(someHandelCode);
Handel.StopHandel();
- And Tonejs should no longer be added as a separate script tag or installed separately.
New Features
- Handel now compiles to Midi. To compile to midi pass in a config object with outputMidi set to true, to the RunHandel function
const config = {outputMidi: true};
Handel.RunHandel(`start play E4 for 1b finish`, config);