Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Audio GvrAudioSource is obsolete. Please upgrade to Resonance Audio

Discussion in 'Audio & Video' started by brianpkenney10, Jun 8, 2019.

  1. brianpkenney10

    brianpkenney10

    Joined:
    Nov 8, 2016
    Posts:
    27
    Hey doing a project for a class and I am getting the following (Unity 2017.4.15):

    Assets/UdacityVR/Scripts/LightUp.cs(78,21): warning CS0618: `GvrAudioSource' is obsolete: `Please upgrade to Resonance Audio (https://developers.google.com/resonance-audio/migrate).'

    I am trying to upgrade to the Resonance Audio Source...imported the resonance audio package and also changed settings in Unity. Struggling with replacing the code. The warnings are from the following code:

    this.GetComponent<GvrAudioSource>().Play();

    I can't find a .Play() method for Resonance. Thought is would just be a simple replace with ResonanceAudioSource. Help?
     
  2. zml9

    zml9

    Joined:
    Oct 1, 2018
    Posts:
    1
    Step 1
    Download the ResonanceAudioForUnity_1.2.1.unitypackage from the releases page
    https://tinyurl.com/ybyld9t3

    Step2
    Import ResonanceAudioForUnity_1.2.1.unitypackage into the project of Unity
    The ResonanceAudio folder will be in project tab.

    Step3
    Using Resonance Audio in Unity
    https://tinyurl.com/y2lgeuv6