Beispiel #1
0
 public void Init()
 {
     //LoadSourceByResources();
     if (native != null)
     {
         BDTtsConfig bdtts  = new BDTtsConfig(Tips.AppID, Tips.APIKey, Tips.SecretKey);
         string      config = JsonUtility.ToJson(bdtts);
         native.InitBDTts(config);
     }
 }
Beispiel #2
0
    void Start()
    {
        if (Application.platform == RuntimePlatform.Android)
        {
            AndroidJavaClass unityPlayer = new AndroidJavaClass("com.unity3d.player.UnityPlayer");
            currentActivity = unityPlayer.GetStatic <AndroidJavaObject>("currentActivity");
            cb     = new ConvertToBase64();
            mAudio = AudioManager.Instance;
        }
        DontDestroyOnLoad(gameObject);
        BDTtsConfig bdtts  = new BDTtsConfig(Tips.AppID, Tips.APIKey, Tips.SecretKey);
        string      config = JsonUtility.ToJson(bdtts);

        InitBDTts(config);
        //arcontrol = GameObject.Find("SceneObj/ARToolKit").GetComponent<ARController>();
    }