예제 #1
0
        private static void OpenAudioGraph()
        {
            AudioGraph graph = GetWindow <AudioGraph>();

            graph.titleContent = new GUIContent("Audio Graph");
            graph.Show();
        }
 /// <summary>
 /// Display a button to open the bank in the graph
 /// </summary>
 public override void OnInspectorGUI()
 {
     if (GUILayout.Button("Open in Graph"))
     {
         AudioGraph.OpenAudioGraph(this.myTarget);
     }
 }
예제 #3
0
        /// <summary>
        /// Display the graph window and automatically open an existing AudioBank
        /// </summary>
        /// <param name="bankToLoad"></param>
        public static void OpenAudioGraph(AudioBank bankToLoad)
        {
            AudioGraph graph = GetWindow <AudioGraph>();

            graph.titleContent = new GUIContent("Audio Graph");
            graph.audioBank    = bankToLoad;
            graph.Show();
        }