I write a Android plugin for Unity3d which can record sound produced by the plugin's client (Unity3d game).
Android has AudioRecord API which I assume can accomplish the task. The problem, however, is that
Applications creating an AudioRecord instance need Manifest.permission.RECORD_AUDIO or the Builder will throw UnsupportedOperationException on build(), and the constructor will return an instance in state STATE_UNINITIALIZED.
Clearly, I don't want the plugin to add permission requirements to its client (unity game). So, I'm looking for another method to capture sound produced by my own application (in that case, it's unity3d game).