AR Design
UBC EML collab with UBC SALA - visualizing IoT data in AR
UAudioManagerTest.cs
Go to the documentation of this file.
1 // Copyright (c) Microsoft Corporation. All rights reserved.
2 // Licensed under the MIT License. See LICENSE in the project root for license information.
3 
4 using System.Collections;
5 using UnityEngine;
6 
7 namespace HoloToolkit.Unity.Tests
8 {
9  public class UAudioManagerTest : MonoBehaviour
10  {
11  [AudioEvent]
12  public string Vocals3d;
13  [AudioEvent]
14  public string VocalsSpatialized;
15  [AudioEvent]
16  public string Laser;
17 
18  private void Start()
19  {
20  StartCoroutine(ContinouslyPlaySounds());
21  }
22 
23  private IEnumerator ContinouslyPlaySounds()
24  {
25  while (true)
26  {
28 
29  yield return new WaitForSeconds(10.0f);
30 
31  UAudioManager.Instance.PlayEvent(VocalsSpatialized);
32 
33  yield return new WaitForSeconds(10.0f);
34 
36 
37  yield return new WaitForSeconds(1.0f);
38  }
39  }
40 
41  }
42 }
The AudioEvent class is the main component of UAudioManager and contains settings and a container for...
Definition: AudioEvent.cs:54
void PlayEvent(string eventName)
Plays an AudioEvent.
static UAudioManager Instance
The UAudioManager class is a singleton that provides organization and control of an application's Aud...