01-02-2018 01:24 PM
Solved! Go to Solution.
01-02-2018 03:07 PM
For #2, you can effect panning by adjustng the distace decay see the options in the first example scene. otherwise it's based on positional audio unless you're using stereo sources.
For #1, it's not explicitly supported but have you ttied with audio clip? I'll try to test this to confirm.
01-02-2018 05:47 PM
Thanks for the speedy response.
Using an audio clip as a sound source will not work for our interactive music application (Jam Studio VR).
All audio produced is streamed to the UI by our Beamz engine in response to dynamic trigger activity.
We examined the audio clip option and it cannot work without substantial architectural changes to our music engine.
Audio (music) played by our app must be dynamic because it will change according to the current musical environment. As songs are played, our Beamz Interactive Music engine tracks the current musical environment and determines which samples (audio clips) to play at any given moment should a (user) trigger be broken. For example, when a song changes keys, different samples will be played (when triggered) that are sympathetic musically with the current key of the song. When the song changes key again, the samples that play will change.
When a trigger is held broken, a series of compatible samples is streamed until the trigger is released.
The Beamz engine manages all of this.
Ideally, it would be perfect if sound emitting objects could accept an audio stream. Just as if someone wanted to put an internet radio somewhere in the VR environment - or maybe a TV.
If you can, I would suggest checking out Jam Studio VR – it will all be clear when you see how it works.
01-02-2018 10:06 PM
Yes I'm familiar with the use cases and I'm not questioning them, just how is it currently implemented in third party engines including yours that would still allow post processing by Unity or specifically by any spatial plugin specified in audio settings in Unity?
01-05-2018 02:36 PM
Sorry for delay.
Basically we need a way to play audio from a buffer.
We would fill the buffer with data from the audio engine stream, which Unity should then apply the spacial effect to and play back. This would be similar to a buffer queue in OpenSL.
Do you know of any way we can do this?
01-05-2018 06:45 PMSolution
Ok so what exactly doesn't work for you after you Audio.Clip.Create(.... and AudioClip.SetData(float  buffer, offset) ? Did you try uncompressed audio data?
01-11-2018 04:35 PM
Our programmers checked out the script reference and they think it will work.
However, they're swamped right now and will not be able to test this out for a few days.
I'll get back to you with feedback as soon as I hear from them.
01-12-2018 01:12 PM
I heard from our programmers today and, although they have not benchmarked yet, they're certain the methods you described will work for streaming audio. There are some small concerns about response latency, but we're confident we can tweak buffer sizes enough to get acceptable latency. If we get into a road block on that, I'll reach out as a new thread.
In the meantime, I will set this thread to resolved.
Thanks for helping us.