Got this response on the android audio list:
On most devices you can achieve this when setting the microphone source to VOICE_RECOGNITION. To do this via the OpenSL interface you have to request the SL_IID_ANDROIDCONFIGURATION interface from the audio recorder object and then set the SL_ANDROID_KEY_RECORDING_PRESET to voice recognition.
These lines should help you if you already have a working OpenSL example.
(*m_engineEngine)->CreateAudioRecorder(m_engineEngine, &m_recorderObject, ... );
(*m_recorderObject)->GetInterface(m_recorderObject, SL_IID_ANDROIDCONFIGURATION, &m_androidConfiguration);
(*m_androidConfiguration)->SetConfiguration(m_androidConfiguration, SL_ANDROID_KEY_RECORDING_PRESET, SL_ANDROID_RECORDING_PRESET_VOICE_RECOGNITION , sizeof(SLint32) );
Unfortunately some devices ignore this, and still apply some processing (AEC,NS,AGC), even though you've set the mic source to voice recognition, but for the majority it works.
Jules, this would require that there would be some way to open an AudioIODevice with an optional set of arguments, like f.i.
virtual String open (const BigInteger& inputChannels,
const BigInteger& outputChannels,
const StringPairArray& optionalArgs = StringPairArray() ) = 0;
where optionalArgs for this particular feature would be:
"InputPreprocessing" = "OFF"
For iOS, there is a similar feature, which is why the optional args stuff would be great :)