public void AudioStreamRenderer() { var obj = new GameObject("audio"); var renderer = new AudioStreamTrack.AudioStreamRenderer(null); renderer.Source = obj.AddComponent <AudioSource>(); renderer.Dispose(); UnityEngine.Object.DestroyImmediate(obj); }
public void AudioStreamRenderer() { var renderer = new AudioStreamTrack.AudioStreamRenderer("test", 48000, 2); Assert.That(renderer.clip, Is.Not.Null); for (int i = 0; i < 300; i++) { float[] data = new float[2048]; renderer.SetData(data); } renderer.Dispose(); }