Overview
Chord of instruments and drums
Example Play La major and drum
package testbox;
import javafx.stage.*;
import javafx.scene.*;
import crudfx.control.*;
import crudfx.interop.*;
import crudfx.sound.*;
Stage{
width:400
height:400
scene:Scene{
content:UINode{
content:StandardButton{
text:"Play"
action:function():Void{
Chord{
part:2
voices:[
Voice{part:2 instrument:24 pitch:57 velocity:1}
,Voice{part:2 instrument:24 pitch:61 velocity:1}
,Voice{part:2 instrument:24 pitch:64 velocity:1}
]
drums:[
Drum{part:2 instrument:35 velocity:1}
,Drum{part:2 instrument:49 velocity:1}
]
}.play(120);
}
}
}
}
}
Profile: desktop
Variable Summary
| access | name | type | Can Read | Can Init | Can Write | Default Value | description |
|---|---|---|---|---|---|---|---|
| public | drums | Drum[] | ![]() | ![]() | ![]() |
Array of drums |
|
| public | part | Number | ![]() | ![]() | ![]() |
Part of whole note ie 16=sixteenth note |
|
| public | voices | Voice[] | ![]() | ![]() | ![]() |
Array of voices |
Inherited Variables
Function Summary
- public play(playTempo: Number) : Void

