cancel
Showing results for 
Search instead for 
Did you mean: 

VoIP Spatialization doesn't work on Rift

GigaSora
Expert Protege
Hey guys, strange problem here.

So I've been trying to get spatialized audio working between two user's (one rift, one go) using Platform sdk Voip and essentially while the VoIP works great, the spatialization doesn't work on Rift, but works on Go. Here's the details.

- Unity 2019.2.8.f1
- Voip hi level .audiosource.spatialized set to true
- Testing between a Rift and a Go
- The Go's spatialization works great with the same code
- The audio settings in project settings for rift and go projects are the same
- Spatializer plugin is set to OculusSpatializer
- Spatial blend doesn't work on rift either (even with spatialize off)
- Other audio sources in the Rift scene use spatial blend or spatialize and it works fine

So its kind of this weird spot where it works on the Go side with the same settings, code, and unity version, and also on Rift for audio sources other than the Go avatar, but not on the Go avatar with audio coming in through VoIP.

It appears to be bypassing the audio source settings, which would be in line with what I'd expect given its using onaudiofilterread and there's no clip set, but then why does it work on the Go? Help appreciated. Or just any way around it.
4 REPLIES 4

GigaSora
Expert Protege
@Heaney-555

Looks like it was just a version problem for me. Updating to 2019.2.20f1 fixed it nicely.

GigaSora
Expert Protege
@Heaney-555

Sorry I was actually incorrect. Upgrading didn't fix it at all haha.

GigaSora
Expert Protege
What did fix it was adding the following code at the end of the awake method in voipaudiosourcehilevel:

await UniRx.Async.UniTask.DelayFrame(2);
audioSource.enabled = false;
filterDelegate.enabled = false;
await UniRx.Async.UniTask.DelayFrame(2);
audioSource.enabled = true;
filterDelegate.enabled = true;


UniTask is just an alternative to task. Basically just turn audiosource and filterdelegate off then back on a couple frames later however you want. It needs a reset it appears.

Linsomont
Protege
Thanks for the information. I would love to try the given tips and see the results.