River Audio

Setting up audio for river and river splines in Unreal 5

UNREAL AUDIO

Chris Chen

9/23/20252 min read

Instead of setting up random emitters for things like rivers, this implementation method allows us to have our audio follow the listener around. I've set it up so that it has smooth interpolation and doesn't skip around and using this method allows spline points to call for different intensities.

Here is a video demo. Apologies for clearing of throat, have some residuals lingering from a cold

Setting up these variables to interpolate smoothly was key. Without this, the audio jumps around a lot, but this probably wouldn't be as necessary in a first person player game depending on the shape of the river. The audio component is placed at a distance that is closet to the listener, and when that listener moves to the next closest distance, instead of teleporting over, we get this smooth transition. It's barely noticeable unless you listen for it, definitely not something players typically think about.

Each point is indexed and that index or range of indexes can be referenced to send data. So where the river has more intense water flow, the spline point ranges send data to the audio to crossfade into heavier water.

This top view is exceptional for setting up spline points and measuring distance units.

I'm running a simple distance to spline check to fade in or fade out audio once at a certain threshold.

Here's an example of setting the water intensity levels based on spline points. Pretty neat stuff.

Here's the full blueprint for the River Audio Spline. To get around U shapes, we can simply set up a child blueprint of this as long as we have randomized seeking starts in our audio setup. All of these setups would be pretty easy to translate to Wwise.