NDKVoice
【博客】AndroidStudio+CMake实现QQ变声效果
NDKVoice: QQ-style voice effects via FMOD
A Chinese blog project that builds a voice changing effect on Android with Android Studio, CMake, and the NDK, piping audio through FMOD's pitch shift DSP.
What the project is
The repository backs a blog post on implementing a QQ-style voice changing effect on Android. The stack is Android Studio with CMake and the NDK, and the audio effect itself runs through the FMOD engine's system and sound APIs, with the project written in C. The blog framing matters here, because the repo is really a worked example rather than a reusable library, and the code follows the post's explanation step by step.
Setting up
Two prerequisites are listed. First, install ndk-build and cmake through the SDK Manager in Android Studio, so the build tooling is in place before any code is written. Second, download the Android platform source from FMOD's official download page, where the README notes you may need a VPN or to contact customer support to get at it. Both steps are spelled out so the environment part does not stall the project.
The FMOD flow
The code process is a short sequence of FMOD calls. Create the system with System_Create, then initialize it with 32 channels and the FMOD_INIT_NORMAL flag. Next, create a sound from a path string with the FMOD_DEFAULT flag, create a pitch shift DSP with createDSPByType, play the sound, and attach the DSP to the channel with addDSP so the effect applies to that stream. The last step closes the resources so the effect does not leak audio handles. That is the whole voice effect in outline, and the pitch shift is where the voice changing actually happens.
Community notes