|
@ -53,18 +53,6 @@ const fluteSynth = new Tone.Sampler({ |
|
|
"F#4": FSharp4Flute, |
|
|
"F#4": FSharp4Flute, |
|
|
}).toDestination(); |
|
|
}).toDestination(); |
|
|
|
|
|
|
|
|
const setRotation = (angle) => { |
|
|
|
|
|
Tone.Listener.forwardX.value = Math.sin(angle); |
|
|
|
|
|
Tone.Listener.forwardY.value = 0; |
|
|
|
|
|
Tone.Listener.forwardZ.value = -Math.cos(angle); |
|
|
|
|
|
}; |
|
|
|
|
|
|
|
|
|
|
|
const setRotationRamp = (panner, angle, rampTime) => { |
|
|
|
|
|
panner.positionX.rampTo(Math.sin(angle), rampTime); |
|
|
|
|
|
panner.positionY.rampTo(0, rampTime); |
|
|
|
|
|
panner.positionZ.rampTo(-Math.cos(angle), rampTime); |
|
|
|
|
|
}; |
|
|
|
|
|
|
|
|
|
|
|
// First three are small, then medium, then large and the link chooses the corresponding motif within the category... |
|
|
// First three are small, then medium, then large and the link chooses the corresponding motif within the category... |
|
|
const calculateDetailMotifVersion = function (textDensity, linkDensity) { |
|
|
const calculateDetailMotifVersion = function (textDensity, linkDensity) { |
|
|
return 3 * textDensity + linkDensity; |
|
|
return 3 * textDensity + linkDensity; |
|
|