Enhanced Audio Occlusion for VR

I made the above comment on the previous page and didn’t read your last comment where you talk about async traces :smiley: Yeah, it’d better to use async traces than sync traces on the game thread!

The thing to watch out for now is CPU core availability and target specs, if you were to ship this. Not all PCs have a ton of cores so even if its async, it can still cause a performance issue… But yeah, if you’re going to do this, you better do it async!

The built-in occlusion traces in UE4 are all async for this reason. Also my built in occlusion is dead simple… 1-trace per sound source so doesn’t do partial occlusion (aka obstruction). :slight_smile:

One issue is you’ll probably want to do the first trace synchronously to make sure its done before the sound plays (so sounds starting occluded don’t “pop” into sounding occluded), OR wait for the async trace to finish before playing the sound.

You should check out Steam Audio’s occlusion features as their solution is really interesting… they basically perform a fluid simulation, compute a filter for a given source-listener pair then apply the filter to sounds dynamically based on source-listener positions. Works pretty well.

Thanks so much for the information! I’ll definitely keep CPU core availability in mind. I threw in a bunch of tweakable parameters so I can customize a sound to do as little as one trace or as much as 12 depending on how important the sound is. I think I can approach it as using only what I must.

And thanks for the tip about popping sounds. I actually haven’t been getting that recently, but I think it’s better to make a safeguard like you said.

I’ll check out Steam Audio’s occlusion approach for sure. I’m still pretty new to programming, but it’s fun to try to figure out how these systems work.

This really does look cool from your demos. I’m trying Steam Audio for occlusion but really haven’t found it very satisfactory so far!

Is there any way to download your solution to play with it and dig through? I’d be fascinated if so, and would be glad of the learning opportunity.

I was looking to do sound reflections and came across this post. Good work! Lots of people asking if your work went public but I can only assume you got hired at Magic Leap and they now use your tech :stuck_out_tongue: