public static void ResetSource(Vive3DSPAudioSource source)
 {
     UpdateListenerTransformCallback();
     foreach (var room in roomList)
     {
         UpdateRoomPositionCallback(room);
         UpdateRoomRotationCallback(room);
     }
     UpdateAllOcclusion();
 }
        public override void OnInspectorGUI()
        {
            Vive3DSPAudioSource model = target as Vive3DSPAudioSource;

            serializedObject.Update();

            EditorGUILayout.Slider(gain, -24.0f, 24.0f, gainLabel);
            bool _dist_mode = EditorGUILayout.Toggle(distanceModeSwitchLabel, model.distanceModeSwitch);

            if (_dist_mode != model.distanceModeSwitch)
            {
                model.distanceModeSwitch = _dist_mode;
            }
            if (_dist_mode == true)
            {
                ++EditorGUI.indentLevel;
                EditorGUILayout.PropertyField(distanceMode, distanceModeLabel);
                if (distanceMode.enumValueIndex == (int)Vive3DSPAudio.Ambisonic3dDistanceMode.QuadraticDecay ||
                    distanceMode.enumValueIndex == (int)Vive3DSPAudio.Ambisonic3dDistanceMode.LinearDecay)
                {
                    ++EditorGUI.indentLevel;
                    EditorGUILayout.LabelField(minimumDecayVolumeTapDbLabel);
                    ++EditorGUI.indentLevel;
                    EditorGUILayout.Slider(minimumDecayVolumeDb, -96.0f, 0.0f, minimumDecayVolumeDbLabel);
                    --EditorGUI.indentLevel;
                    --EditorGUI.indentLevel;
                }
                --EditorGUI.indentLevel;
            }


            EditorGUILayout.PropertyField(drc, drcLabel);
            EditorGUILayout.PropertyField(spatializer, spatializerLabel);
            EditorGUILayout.PropertyField(reverb, reverbLabel);
            EditorGUILayout.PropertyField(occlusion, occlusionLabel);

            EditorGUILayout.Separator();

            if (GUI.changed)
            {
                serializedObject.ApplyModifiedProperties();
                EditorUtility.SetDirty(target);
                if (!Application.isPlaying)
                {
                    UnityEditor.SceneManagement.EditorSceneManager.MarkSceneDirty(UnityEditor.SceneManagement.EditorSceneManager.GetActiveScene());
                }
            }
        }
 public static void DestroySource(Vive3DSPAudioSource source)
 {
     srcList.Remove(source);
 }
 // Source
 public static void CreateSource(Vive3DSPAudioSource srcComponent)
 {
     srcList.Add(srcComponent);
 }