Exemple #1
0
        void OnEnable()
        {
            if (lipSync.profile == null)
            {
                lipSync.profile = EditorUtil.FindAsset <Profile>(Common.defaultProfileWoman);
            }

            if (lipSync.config == null)
            {
                lipSync.config = EditorUtil.FindAsset <Config>(Common.defaultConfig);
            }
        }
Exemple #2
0
 void DrawSetProfileButtons()
 {
     EditorGUILayout.BeginHorizontal();
     GUILayout.FlexibleSpace();
     if (GUILayout.Button("Man", EditorStyles.miniButtonLeft, GUILayout.Width(80)))
     {
         lipSync.profile = EditorUtil.FindAsset <Profile>(Common.defaultProfileMan);
     }
     if (GUILayout.Button("Woman", EditorStyles.miniButtonMid, GUILayout.Width(80)))
     {
         lipSync.profile = EditorUtil.FindAsset <Profile>(Common.defaultProfileWoman);
     }
     if (GUILayout.Button("Create", EditorStyles.miniButtonRight, GUILayout.Width(80)))
     {
         lipSync.profile = EditorUtil.CreateAssetInRoot <Profile>($"{Common.assetName}-Profile-New");
     }
     EditorGUILayout.EndHorizontal();
 }
Exemple #3
0
 void DrawSetConfigButtons()
 {
     EditorGUILayout.BeginHorizontal();
     GUILayout.FlexibleSpace();
     if (GUILayout.Button("Default", EditorStyles.miniButtonLeft, GUILayout.Width(80)))
     {
         lipSync.config = EditorUtil.FindAsset <Config>(Common.defaultConfig);
     }
     if (GUILayout.Button("Calibration", EditorStyles.miniButtonMid, GUILayout.Width(80)))
     {
         lipSync.config = EditorUtil.FindAsset <Config>(Common.calibrationConfig);
     }
     if (GUILayout.Button("Create", EditorStyles.miniButtonRight, GUILayout.Width(80)))
     {
         lipSync.config = EditorUtil.CreateAssetInRoot <Config>($"{Common.assetName}-Config-New");
     }
     EditorGUILayout.EndHorizontal();
 }