Code example for Visualizer

Methods: setEnabled

        // When the stream ends, we don't need to collect any more data. We don't do this in 
        // setupVisualizerFxAndUI because we likely want to have more, non-Visualizer related code 
        // in this callback. 
        mMediaPlayer.setOnCompletionListener(new MediaPlayer.OnCompletionListener() {
            public void onCompletion(MediaPlayer mediaPlayer) {
        mStatusTextView.setText("Playing audio...");
    private void setupEqualizerFxAndUI() { 
        // Create the Equalizer object (an AudioEffect subclass) and attach it to our media player, 
        // with a default priority (0). 
        mEqualizer = new Equalizer(0, mMediaPlayer.getAudioSessionId());
        TextView eqTextView = new TextView(this);
Connect your IDE to all the code out there  Get Codota for Java