How to Beautify and Convert the User’s Voice Using the Agora Android SDK

Not everyone likes the sound of their voice. Many people feel nervous or don’t join video calls because they feel that their voices are horrible. Fortunately, Agora has a solution for those users. Agora gives you the ability to alter your voice by converting it to a voice you like or by beautifying the voice. This is a fun feature that can make your video calls more enjoyable.

In this tutorial, we will learn how to alter (voice conversion) and beautify the voice using the Agora Android SDK.


  • An Agora developer account (Sign up here).
  • Knowledge of how to create a live-streaming Android application using Agora. Check out the tutorial here.
  • Basic knowledge of Android development.
  • Android Studio.

Adding dependencies in Gradle

Add the following dependencies in your build.gradle in the app module, and sync to download the Agora third-party library. Ensure that you always use the latest Agora library version:

Adding permissions in the Manifest.xml file

Go ahead and add the following permissions in the Manifest.xml file:

Creating an instance of the RtcEngine

Now, let’s create an RtcEngine instance by initializing the RtcEngine, and pass the IRtcEngineEventHandler and your App ID to the create method. IRtcEngineEventHandler is an abstract class that provides the default implementation:

Setting the client as a broadcaster

Next, we will set the channel profile as CHANNEL_PROFILE_LIVE_BROADCASTING and set the client role as CLIENT_ROLE_BROADCASTER. We do this because the user has to send and receive streams. You can set the channel profile as an audience if you want the user to receive streams only:

Beautifying the voice

The setVoiceBeautifierPreset takes in the beautifying value. The function then alters and sets the voice of the user as beautiful based on the beautifying value chosen. By default, the beautifying value will be off, VOICE_BEAUTIFIER_OFF. The voice beautifier makes the user’s voice beautiful without changing the original voice:

Converting the voice of the user

Converting the voice of the user completely alters the voice of the speaker. Listeners will not be able to recognize the broadcaster’s voice. This is a great feature for users who want to remain anonymous or who don’t have confidence in their voice.

The setVoiceConversionPreset function takes in the voice conversion value. We will use this function to convert the voice of the user:

Testing the demo

In the demo below, we will test our source code by changing the voice of the user speaking to a bass voice.


In this tutorial we have learned how to:

  • Beautify the voice of the user
  • Completely change the voice of the user
  • Set a client as a broadcaster and create an instance of the RTC engine


Cheers, you now know how to change and beautify the user’s voice!

Thank you for reading. You can learn more on how to alter the user’s voice here and also check out more Agora features on GitHub here. If you want to copy or reference the SDK I was using, check it on GitHub here.

Other resources

If you are getting confused in the process, you can check out Agora’s documentation. You can also join Agora’s Slack channel here.

This article was originally posted on the Agora Blog:

How to Beautify and Convert the User’s Voice Using the Agora Android SDK



--|Android developer| Tech Enthusiast|Innovative thinking is my passion | Learn and experience more to discover more

Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

Horizontal Calendar with RecyclerView

Wwe 13 For Ppsspp

How you can parcel an OnClickListener in an Android Bundle — but shouldn’t!

Android Kotlin — Apple Login with Firebase


Oculus Quest Postmortem

IllegalStateException: You used a fragment

Android Tutorial: Activity-Related Intents

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Boemo Mmopelwa

Boemo Mmopelwa|Android developer| Tech Enthusiast|Innovative thinking is my passion | Learn and experience more to discover more

More from Medium

Building voice powered To-Do list Android App with Alan AI

How to get crash log from android device with adb logcat

How Integrated Ads Kit: Banner Ads (Java) ==Android Studio (Arctic Fox)==

How to Mute Audio and Adjust Volume During a Video Call in Android Using the Agora SDK