Ejemplo n.º 1
0
        private void OnGUI()
        {
            //GUIStyle fontStyle = new GUIStyle();

            GUI.skin.button.fontSize = 30;
            if (GUI.Button(new Rect(40, 40, 100, 60), "切换"))
            {
                BaiduARWebCamera aw = FindObjectOfType <BaiduARWebCamera>();
                aw.SwitchCamera();
                //CheckEffect(0, lstVets[0].VectorScreenPos, lstVets[1].VectorScreenPos, lstVets[2].VectorScreenPos);
            }

            if (GUI.Button(new Rect(300, 40, 100, 60), "暂停"))
            {
                BaiduARHumanPose aw = FindObjectOfType <BaiduARHumanPose>();
                aw.PauseAR();

                objs.Clear();
                electRoot.HideElectric();
                //CheckEffect(0, lstVets[0].VectorScreenPos, lstVets[1].VectorScreenPos, lstVets[2].VectorScreenPos);
            }

            if (GUI.Button(new Rect(450, 40, 100, 60), "继续"))
            {
                BaiduARHumanPose aw = FindObjectOfType <BaiduARHumanPose>();
                aw.ResumeAR();
                //CheckEffect(0, lstVets[0].VectorScreenPos, lstVets[1].VectorScreenPos, lstVets[2].VectorScreenPos);
            }
        }
Ejemplo n.º 2
0
 private void OnGUI()
 {
     if (GUI.Button(new Rect(20, 20, 100, 100), "switch"))
     {
         BaiduARWebCamera aw = FindObjectOfType <BaiduARWebCamera>();
         aw.SwitchCamera();
     }
 }