How do I get the current volume/amplitude in a MediaPlayer?

前端 未结 7 874
孤街浪徒
孤街浪徒 2020-12-13 20:26

I\'m working on an app that will both record an audio file, and then have the option to play back that file once it\'s been recorded. The UI has an EQ component that animat

相关标签:
7条回答
  • 2020-12-13 20:56

    I think you have to use AudioManager. As the API states it can be used for volume control:

    AudioManager provides access to volume and ringer mode control.

    Use Context.getSystemService(Context.AUDIO_SERVICE) to get an instance of this class.

    Then I think this method would be useful.

    0 讨论(0)
提交回复
热议问题