public static int getCurrentVolume ( Context context ) { AudioManager mAudioManager = ( AudioManager ) context . getSystemService ( Context . AUDIO_SERVICE ) ; return mAudioManager . getStreamVolume ( AudioManager . STREAM_MUSIC ) ; }
Returns current media volume