I am trying to create an application that reproduces a sound similar to a piano organ. When the user presses the button, he will play a sound similar to a piano. The difficulty is that the user can hold his finger for some time. When they take their finger away, it should disappear, and not stop suddenly.
I played with SoundPool and Media Player, but they do not seem to be suitable.
There are many applications for the piano ... does anyone know how they solve this problem?
source
share