madronalabs / soundplane

Client software for the Madrona Labs Soundplane.
32 stars 11 forks source link

Retain final key pitch on release. #2

Closed ngwese closed 10 years ago

ngwese commented 10 years ago

Prior to the introduction of Zones when a touch was released the final key pitch was retained. The Zones logic in 1.0a1 would send "touch off" messages with the key value based on the last touch sample. Since the last touch sample (t1) is post release the x position is always 0 which resulted in the final key pitch always being the lowest key in the zone. Sounds with a long release envelope would pitch downward to the root key of the zone on touch release (effected both Aalto and Kyma in my testing).

The patch changes the "touch off" key to match that of the last know touch (t2) prior to release.

ngwese commented 10 years ago

I should note that I didn't extensively test to see if MIDI output was effected by this change. A quick inspection with MIDI Monitor showed that for every note on, two note off messages are getting generated (one for the triggered note and a second for key C-2).

madronalabs commented 10 years ago

Looks mostly good, I added a fix to restore the quantized pitch without vibrato on release. Thanks for the help.