Voicemod Voice Changer

Updated

Install and enable the Voicemod voice changer extension.

This guide is provided by Voicemod. Agora is planning a documentation upgrade program for all extensions on the marketplace. Please stay tuned.

Integrate Voicemod extension

You download the libraries and example code from the Agora dashboard.

Place the aar file into the libs folder of your project and link to the file in build.gradle:

dependencies {
    implementation(name: 'voicemod-audio-filter-extension', ext: 'aar')
}

Enable the extension

There is currently no callback that notifies the app when the extension has been enabled, and enabling the extension can take up to a few seconds.

public void initializeAgoraEngine() {
    RtcEngineConfig config = new RtcEngineConfig();
    config.addExtension("VoicemodExtension");
    mRtcEngine = RtcEngine.create(config);
    mRtcEngine.enableExtension("Voicemod", "VoicemodExtension", true);
}

Disable the extension

Disable the extension when your app closes. You will eventually be charged for usage, so it is important to shut it down before exit.

mRtcEngine.enableExtension("Voicemod", "VoicemodExtension", false);

Initialize Voicemod

To start the extension, set your project’s API key and API secret.

A request to initialize the Voicemod extension fails unless the extension has already been enabled successfully.

public void initVoicemodSession(String userId) {
    String userData = "{"
        + "\"apiKey\": \"<your API key>\","
        + "\"apiSecret\": \"<your API secret>\""
        + "}";
    mRtcEngine.setExtensionProperty(
        "Voicemod",
        "VoicemodExtension",
        "vcmd_user_data",
        userData
    );
}

Enable a voice

A request to set the voice fails unless the Voicemod extension has been initialized successfully.

String voice = "\"titan\"";
mRtcEngine.setExtensionProperty("Voicemod", "VoicemodExtension", "vcmd_voice", voice);

Disable voices

String voice = "null";
mRtcEngine.setExtensionProperty("Voicemod", "VoicemodExtension", "vcmd_voice", voice);

Reference

Voicemod properties

You can configure and control the Voicemod extension using the following properties.

Before you can use the extension, you must provide your API key and API secret by setting the vcmd_user_data property.

Except for vcmd_user_data and vcmd_version, the extension must be initialized before Voicemod property accessors work.

Property keyProperty valueAccessDescription
vcmd_user_dataObject: { apiKey: "project API key", apiSecret: "project API secret" }SetSets the API key and API secret.
vcmd_versionString: MAJOR.MINOR.PATCHGetGets the Voicemod plugin version.
vcmd_voiceStringGet, setSets or gets the current voice. Use null for no voice.
vcmd_presetsArray of strings, such as magic-chords, baby, cave, titan, robot, and lost-soulGetGets the list of existing voices.
vcmd_background_soundsBooleanSetToggles background sounds.
vcmd_muteBooleanGet, setToggles mute audio samples or gets the current setting.

FAQ

How do I add the extension to my Agora Marketplace app?

To use the extension, download the files for your operating systems from the Voicemod Agora releases repository, and follow the instructions in the Voicemod documentation.

How large is the extension?

The extension currently uses 14 MB of storage space for Android and 32 MB for iOS.

What pricing plans are available?

The extension is free until December 31, 2021, and will be charged at $1 per 1000 minutes after that.

What are Voicemod's terms and conditions?

Read the Voicemod End User License Agreement.

Can I get more voices?

Voicemod plans to release an extended voice pack soon.

Can I use other Voicemod features such as Soundboard?

Voicemod does not currently support Soundboard within an Agora Marketplace app, but is working on it for v2 of the extension.