Setup espeak TTS. Fix "velocity" -> "gain".

I was originally thinking the velocity sensor would adjust the midi note velocity.
The downside to this is that you have to wait for a note to play to "feel" the volume change.

When changed to alter the gain of the synth itself, it is much smoother -- works for any
sound, even those that have already started playing.

FossilOrigin-Name: 9b5a893d5b6e3aed1e11d0b984b5f498d9b67f55cda304bbef4179944ca6260f
This commit is contained in:
Mahlon E. Smith 2023-05-12 06:44:09 +00:00
parent 5a4fcbae87
commit 7bc47cfc4d
4 changed files with 58 additions and 35 deletions

View file

@ -54,7 +54,7 @@ class FluidSynth
@host = host
@port = port
@lastnote = nil
@velocity = 0
@velocity = 80
end
# The TCP socket to fluidsynth.