A simple Unreal 5 plugin with demo content that shows how audio DSP processing can be done implementing a Metasound Node, SourceEffect and SubmixEffect.
A volume effect with its amplitude parameter is used to demonstrate how to do basic DSP processing.
The intention of this project is to use it as a start point to create more complex audio DSP effects.
The most relevant parts of the code are located in:
- Plugins/AudioDSPTemplate/Source/AudioDSPTemplate/Private
- Plugins/AudioDSPTemplate/Source/AudioDSPTemplate/Public
- Clone repository
- Right click UEAudioDSPTemplate.uproject > Generate Visual Studio projects files
- Open UEAudioDSPTemplate.sln
- Build Solution
- Open UEAudioDSPTemplate.uproject (or start it from Visual Studio)
- DemoMap will be automatically loaded
- Metasound:
- Open VolumeNode_Metasound asset
- Click Play button to start the Metasound
- SourceEffect and SubmixEffect:
- Go to Blueprints > Open Level Blueprint
- You will see that there is Blueprint logic to trigger a sound at the Sphere location and a Timeline that will drive the Amplitude parameter of the SourceEffect
- If you want to test the Submix effect simply connect the Update port from Timeline to the Set Settings node of the SubmixEffect
- Click Play button to start the Level
- If you plan to create new Metasound nodes in your own project don't forget to call
FMetasoundFrontendRegistryContainer::Get()->RegisterPendingNodes();
in theStartupModule()
method, checkAudioDSPTemplate.cpp
for more details.