Example #1
0
        /// <summary>
        /// 退出Blending
        /// </summary>
        void ExitBlending()
        {
            mode = FoldingMode.DoingNothing;
            currentModeVi.End();
            currentModeVi = null;
            blendAngleVi.End();
            blendAngleVi = null;

            // 向下层传递退出Blending模式
            CloverController.GetInstance().Blending.ExitBlendingMode();
        }
Example #2
0
 /// <summary>
 /// 进入Blending
 /// </summary>
 void EnterBlending()
 {
     mode = FoldingMode.Blending;
     // 计算旋转
     Quaternion quat = CalculateBlendingRotation();
     // 应用旋转
     RenderController.GetInstance().BeginRotationSlerp(quat);
     // 显示模式
     currentModeVi = new CurrentModeVisual("Blending Mode");
     VisualController.GetSingleton().AddVisual(currentModeVi);
     currentModeVi.Start();
     // 显示纸张夹角vi
     blendAngleVi = new BlendAngleVisual(0, new Point(100, 100), new Point(200, 200));
     VisualController.GetSingleton().AddVisual(blendAngleVi);
     blendAngleVi.Start();
 }