A better solution would be to do this with a native call.
It's impossible. You do not have access to the audio stream in a conversation, except possibly in speakerphone mode.
But restoring a phone application (without VOIP) would also be nice.
The last official word from Google (2010), the entire OS does not have access to the audio stream in the conversation, since everything is processed at a lower level. Even if newer versions of Android have access to the audio stream in a conversation, "rebuilding the phone application" is only possible when creating custom firmware.
source
share