• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

C# PlaneProjection类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C#中PlaneProjection的典型用法代码示例。如果您正苦于以下问题:C# PlaneProjection类的具体用法?C# PlaneProjection怎么用?C# PlaneProjection使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



PlaneProjection类属于命名空间,在下文中一共展示了PlaneProjection类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。

示例1: DrawLeftPage

        private void DrawLeftPage()
        {
            //Tworzę obiekt canvas
            Canvas cv = new Canvas();
            cv.Width = 100;
            cv.Height = 100;
            SolidColorBrush sb = new SolidColorBrush(Color.FromArgb(255, 0, 255, 255));
            cv.Background = sb;
            Canvas.SetLeft(cv, 150);
            Canvas.SetTop(cv, 100);

            //Projekcja
            PlaneProjection pp = new PlaneProjection();
            pp.LocalOffsetX = -50.0;
            cv.Projection = pp;

            //Dodaję canvas
            plutno.Children.Add(cv);

            //Tworzę animację
            stL = new Storyboard();
            DoubleAnimation db = new DoubleAnimation();
            db.Duration = new Duration(TimeSpan.FromMilliseconds(1000));
            db.From = 0.0;
            db.To = -180.0;

            Storyboard.SetTarget(db, pp);
            Storyboard.SetTargetProperty(db, new PropertyPath(PlaneProjection.RotationYProperty));

            //Dodanie animacji do storyboarda
            stL.Children.Add(db);
        }
开发者ID:dawidwekwejt,项目名称:KCK_projekt,代码行数:32,代码来源:MainPage.xaml.cs


示例2: LightBoxView

        public LightBoxView()
            : base()
        {
            this.projection = new PlaneProjection();

            this.timer = new DispatcherTimer();
            this.timer.Tick += new EventHandler(OnTick);
            this.image.Projection = new PlaneProjection();
        }
开发者ID:sunnnjin,项目名称:Blackbox,代码行数:9,代码来源:LightBoxView.cs


示例3: SetProjection

 private void SetProjection(double xAngle, double yAngle)
 {
     PlaneProjection projection = Projection as PlaneProjection;
     if (projection == null)
     {
         projection = new PlaneProjection();
         Projection = projection;
     }
     projection.RotationX = xAngle;
     projection.RotationY = yAngle;
 }
开发者ID:michaellperry,项目名称:MyCon,代码行数:11,代码来源:SessionUserControl.cs


示例4: Star

 public Star(ImageSource source, double size)
 {
     Image image = new Image();
     image.Source = source;
     image.Projection = new PlaneProjection();
     this.projection = (PlaneProjection)image.Projection;
     image.Opacity = GlobalValue.OPACITY;
     image.Width = size;
     image.Height = size;
     this.Children.Add(image);
 }
开发者ID:sunnnjin,项目名称:Blackbox,代码行数:11,代码来源:Star.cs


示例5: MemoSummaryControl

    /// <summary>
    /// CTOR
    /// </summary>
    public MemoSummaryControl()
    {
      _planeprojection = new PlaneProjection
      {
        CenterOfRotationX = 0.5,
        CenterOfRotationY = 0.5
      };
      this.Projection = _planeprojection;

      this.ManipulationStarted += new EventHandler<ManipulationStartedEventArgs>(OnManipStarted);
      this.ManipulationDelta += new EventHandler<ManipulationDeltaEventArgs>(OnManipDelta);
      this.ManipulationCompleted += new EventHandler<ManipulationCompletedEventArgs>(OnManipulationCompleted);
    }
开发者ID:popopome,项目名称:memocloud,代码行数:16,代码来源:MemoSummaryControl.cs


示例6: CreateEffectAnimation

        /// <internalonly />
        protected internal override ProceduralAnimation CreateEffectAnimation(AnimationEffectDirection direction)
        {
            FrameworkElement target = GetTarget();

            if (_projection == null) {
                _projection = target.Projection as PlaneProjection;
                if (_projection == null) {
                    _projection = new PlaneProjection();
                    _projection.CenterOfRotationX = 0.5;
                    _projection.CenterOfRotationY = 0.5;
                    _projection.CenterOfRotationZ = 0.5;

                    target.Projection = _projection;
                }
            }

            DoubleAnimation zOffsetAnimation =
                new DoubleAnimation(_projection, PlaneProjection.GlobalOffsetZProperty, Duration,
                                    (direction == AnimationEffectDirection.Forward ? Distance : 0));
            zOffsetAnimation.Interpolation = GetEffectiveInterpolation();

            if (_shadowLength == 0) {
                zOffsetAnimation.AutoReverse = AutoReverse;

                return zOffsetAnimation;
            }

            if (_dropShadow == null) {
                _dropShadow = target.Effect as DropShadowEffect;
                if (_dropShadow == null) {
                    _dropShadow = new DropShadowEffect();
                    _dropShadow.BlurRadius = 0;
                    _dropShadow.ShadowDepth = 0;
                    _dropShadow.Color = Colors.Black;
                    _dropShadow.Opacity = 0.5;

                    target.Effect = _dropShadow;
                }
            }

            DoubleAnimation shadowAnimation =
                new DoubleAnimation(_dropShadow, DropShadowEffect.BlurRadiusProperty, Duration,
                                    (direction == AnimationEffectDirection.Forward ? _shadowLength : 0));
            shadowAnimation.Interpolation = GetEffectiveInterpolation();

            ProceduralAnimationSet animationSet = new ProceduralAnimationSet(zOffsetAnimation, shadowAnimation);
            animationSet.AutoReverse = AutoReverse;

            return animationSet;
        }
开发者ID:nikhilk,项目名称:silverlightfx,代码行数:51,代码来源:Float.cs


示例7: LayoutRoot_Loaded

        // Load WelcomePromo user control
        private void LayoutRoot_Loaded(object sender, RoutedEventArgs e)
        {
            if (this.timer == null)
            {
                this.timer = new DispatcherTimer();
                this.timer.Interval = TimeSpan.FromMilliseconds(50);
                this.timer.Tick += new EventHandler(timer_Tick);
                this.timer.Start();
            }

            Reset(); // reset all rectangles

            this.curRectangle = GetCurrentRectangle();
            this.projection = (PlaneProjection)this.curRectangle.Projection;
        }
开发者ID:sunnnjin,项目名称:Blackbox,代码行数:16,代码来源:WelcomePromo.xaml.cs


示例8: UpdateStateValue

 public override void UpdateStateValue(BoxData newState)
 {
     state = newState;
     if (state._state == LightBox.ConcealState)
     {
         this.image.Source = GetLightBoxImage(state);
         this.image.Stretch = Stretch.UniformToFill;
     }
     else
     {
         this.projection = (PlaneProjection)this.image.Projection;
         this.projection.RotationX = 0;
         this.timer.Interval = TimeSpan.FromMilliseconds(50);
         this.timer.Start();
     }
 }
开发者ID:sunnnjin,项目名称:Blackbox,代码行数:16,代码来源:LightBoxView.cs


示例9: CreateImagePushpin

        /// <summary>
        /// Creates an Image pushpin
        /// </summary>
        /// <param name="imageUri">Uri of the image to use for the pushpin icon</param>
        /// <param name="width">Width of the pushpin</param>
        /// <param name="height">Height of the pushpin</param>
        /// <param name="offset">Offset distance for the pushpin so that the point of the 
        /// pin is aligned with the associated coordinate.</param>
        /// <returns></returns>
        public static UIElement CreateImagePushpin(Uri imageUri, double width, double height, int rotateTr, Point offset, PlaneProjection planeProjection)
        {
            //Source.RenderTransform.r
            //TransformGroup
            RotateTransform RotateTr = new RotateTransform();
            RotateTr.Angle = rotateTr;

            return new Image()
            {
                Source = new BitmapImage(imageUri),
                //RenderTransform = RotateTr,
                Width = width,
                Height = height,
                //Stretch = System.Windows.Media.Stretch.Uniform,
                //VerticalAlignment = VerticalAlignment.Center,
                //HorizontalAlignment = HorizontalAlignment.Center,
                Margin = new Thickness(offset.X, offset.Y, 0, 0),
                Projection = planeProjection,

            };
        }
开发者ID:HogwartsRico,项目名称:AGS-PgRouting,代码行数:30,代码来源:PushpinTools.cs


示例10: CreateStoryboard

        protected override Storyboard CreateStoryboard(FrameworkElement target)
        {
            Storyboard result = new Storyboard();
            if (target != null)
            {
                DoubleAnimation animation = new DoubleAnimation();
                animation.From = From;
                animation.To = To;
                if (Speed != -1)
                    animation.SpeedRatio = Speed;
                if (Duration != -1)
                {
                    animation.SpeedRatio = 1;
                    animation.Duration = TimeSpan.FromMilliseconds(Duration);
                }
                EasingFunction.EasingMode = Mode;
                PlaneProjection projection = new PlaneProjection();
                target.Projection = projection;
                animation.EasingFunction = EasingFunction;
                Storyboard.SetTarget(animation, projection);
                if(RotationCenter!=null){
                    projection.CenterOfRotationX=RotationCenter.X;
                    projection.CenterOfRotationY=RotationCenter.Y;
                }

                if (RotationAxe == null)
                {
                    RotationAxe = PlaneProjection.RotationYProperty;
                }
                Storyboard.SetTargetProperty(animation, new PropertyPath(RotationAxe));

                result.Children.Add(animation);
            }
            else
            {
                Debugger.Log(1, "animation", "target is null for RotateEffect");
            }
            return result;
        }
开发者ID:fstn,项目名称:WindowsPhoneApps,代码行数:39,代码来源:RotateEffect.cs


示例11: NookBoxView

        public NookBoxView()
            : base()
        {
            this.projection = new PlaneProjection();

            this.image.Source =
                BlackboxImageUtils.Image(BlackboxImageType.NookBoxBackground);
            this.imageForeground.Source =
                BlackboxImageUtils.Image(BlackboxImageType.NookBoxForeground);
            this.imageForeground.Projection = new PlaneProjection();
            this.projection = (PlaneProjection)this.imageForeground.Projection;

            this.rotatedTimer = new DispatcherTimer();
            this.rotatedTimer.Interval = TimeSpan.FromMilliseconds(RotatedTimeSpane);
            this.rotatedTimer.Tick += new EventHandler(OnRotatedTimerTick);
            this.rotatedTimer.Start();
            this.speed = NormalSpeed;

            this.acceleratedTimer = new DispatcherTimer();
            this.acceleratedTimer.Interval = TimeSpan.FromMilliseconds(AcceleratedTimeSpan);
            this.acceleratedTimer.Tick += new EventHandler(OnAcceleratedTimerTick);
        }
开发者ID:sunnnjin,项目名称:Blackbox,代码行数:22,代码来源:NookBoxView.cs


示例12: PrepareGrowStoryBoard

        /// <summary>
        /// 由小到大显示Element
        /// </summary>
        /// <param name="Element">需要应用Storyboard的对象</param>
        /// <param name="seconds">动画处理时间</param>
        /// <returns>已经根据Element封装好的动画,返回的Storyboard直接使用Begin函数即可</returns>
        public static Storyboard PrepareGrowStoryBoard(FrameworkElement Element, double seconds)
        {
            PlaneProjection _planePrj = new PlaneProjection();
            Element.Projection = _planePrj;
            Storyboard _storyboard = new Storyboard();
            TransformGroup transGroup = new TransformGroup();
            ScaleTransform scaletrans = new ScaleTransform();
            transGroup.Children.Add(scaletrans);
            scaletrans.CenterX = 0.5;
            scaletrans.CenterY = 0.5;
            Element.RenderTransform = transGroup;
            Element.RenderTransformOrigin = new Point(0.5, 0.5);

            DoubleAnimation doubleX = new DoubleAnimation();
            doubleX.From = 0;
            doubleX.To = 1;
            doubleX.FillBehavior = FillBehavior.HoldEnd;
            _storyboard.Children.Add(doubleX);

            DoubleAnimation doubleY = new DoubleAnimation();
            doubleY.From = 0;
            doubleY.To = 1;
            doubleY.FillBehavior = FillBehavior.HoldEnd;
            _storyboard.Children.Add(doubleY);
            //调用封装透明度和旋转X轴方法
            AddDoubleAnimation(Element, seconds, _storyboard);

            Storyboard.SetTarget(doubleX, Element);
            Storyboard.SetTargetProperty(doubleX,
               new PropertyPath("(UIElement.RenderTransform).(transGroup.Children)[0].(ScaleTransform.ScaleX)"));
            Storyboard.SetTarget(doubleY, Element);
            Storyboard.SetTargetProperty(doubleY,
               new PropertyPath("(UIElement.RenderTransform).(transGroup.Children)[0].(ScaleTransform.ScaleY)"));
            _storyboard.Completed += (s, e) => { _storyboard.Stop(); };
            return _storyboard;
        }
开发者ID:JuRogn,项目名称:OA,代码行数:42,代码来源:CommonAnimation.cs


示例13: TryAttachProjectionAndTransform

        /// <summary>
        /// Prepares a framework element to be feathered by adding a plane projection
        /// and a composite transform to it.
        /// </summary>
        /// <param name="root">The root visual.</param>
        /// <param name="element">The framework element.</param>
        private static bool TryAttachProjectionAndTransform(PhoneApplicationFrame root, FrameworkElement element)
        {
            GeneralTransform generalTransform;

            try
            {
                generalTransform = element.TransformToVisual(root);
            }
            catch (ArgumentException)
            {
                return false;
            }

            Point coordinates = generalTransform.Transform(Origin);
            double y = coordinates.Y + element.ActualHeight / 2.0;
            double offset = (root.ActualHeight / 2.0) - y;

            // Cache original projection and transform.
            TurnstileFeatherEffect.SetOriginalProjection(element, element.Projection);
            TurnstileFeatherEffect.SetOriginalRenderTransform(element, element.RenderTransform);

            // Attach projection.
            PlaneProjection projection = new PlaneProjection();
            projection.GlobalOffsetY = offset * -1.0;
            projection.CenterOfRotationX = FeatheringCenterOfRotationX;
            element.Projection = projection;

            // Attach transform.
            Transform originalTransform = element.RenderTransform;
            TranslateTransform translateTransform = new TranslateTransform();
            translateTransform.Y = offset;
            TransformGroup transformGroup = new TransformGroup();
            transformGroup.Children.Add(originalTransform);
            transformGroup.Children.Add(translateTransform);
            element.RenderTransform = transformGroup;

            return true;
        }
开发者ID:5nophilwu,项目名称:S1Nyan,代码行数:44,代码来源:TurnstileFeatherEffect.cs


示例14: DisplayHandCards

        private void DisplayHandCards()
        {
            var element = new HandCardsElement(Player.HandCards,
            showFaces: true,
            rotationAngle: 0,
            displayCardCount: false)
                      {
                        CardWidth = myHandCardsElement.CardWidth,
                        CardHeight = myHandCardsElement.CardHeight,
                      };

              UIElement rootVisual = Application.Current.RootVisual;
              var startRect = myHandCardsElement.GetRect(rootVisual);
              var endRect = new Rect(0, 0, rootVisual.RenderSize.Width, rootVisual.RenderSize.Height);
              const double endXStep = 1.1;
              double endCardWidth = rootVisual.RenderSize.Width / (Player.HandCards.Count * endXStep + 2 * (endXStep - 1));
              double endCardHeight = myHandCardsElement.CardHeight * endCardWidth / myHandCardsElement.CardWidth;
              var projection = new PlaneProjection();
              element.Projection = projection;
              myHandCardsElement.Visibility = Visibility.Collapsed;
              myHandCardsElement.NavigationAction = null;
              Cursor = Cursors.Arrow;
              Action onClosed = delegate
                          {
                            myHandCardsElement.Visibility = Visibility.Visible;
                            Timer timer = null;
                            timer = new Timer(delegate
                                                {
                                                  myHandCardsElement.NavigationAction = DisplayHandCards;
                                                  timer.Dispose();
                                                },
                                                null, 500, int.MaxValue);
                          };
              UIManager.Instance.ShowInPopup(element, startRect, endRect, onClosed,
                                     new AnimationInfo(element, new PropertyPath(HandCardsElement.XStepProperty), myHandCardsElement.XStep, endXStep),
                                     new AnimationInfo(element, new PropertyPath(HandCardsElement.MaxAngleProperty), myHandCardsElement.MaxAngle, 0),
                                     new AnimationInfo(element, new PropertyPath(HandCardsElement.AngleStepProperty), myHandCardsElement.AngleStep, 0),
                                     new AnimationInfo(element, new PropertyPath(HandCardsElement.CardWidthProperty), myHandCardsElement.CardWidth, endCardWidth),
                                     new AnimationInfo(element, new PropertyPath(HandCardsElement.CardHeightProperty), myHandCardsElement.CardHeight, endCardHeight),
                                     new AnimationInfo(projection, new PropertyPath(PlaneProjection.RotationXProperty), -45, 0));
        }
开发者ID:valentinkip,项目名称:Test,代码行数:41,代码来源:PlayerPanel.cs


示例15: PrepareControlForTilt

        /// <summary>
        /// Prepares a control to be tilted by setting up a plane projection and some event handlers
        /// </summary>
        /// <param name="element">The control that is to be tilted</param>
        /// <param name="centerDelta">Delta between the element's center and the tilt container's</param>
        /// <returns>true if successful; false otherwise</returns>
        /// <remarks>
        /// This method is pretty conservative; it will fail any attempt to tilt a control that already
        /// has a projection on it
        /// </remarks>
        static bool PrepareControlForTilt(FrameworkElement element, Point centerDelta)
        {
            // Don't clobber any existing transforms
            if (element.Projection != null || (element.RenderTransform != null && element.RenderTransform.GetType() != typeof(MatrixTransform)))
                return false;

            TranslateTransform transform = new TranslateTransform();
            transform.X = centerDelta.X;
            transform.Y = centerDelta.Y;
            element.RenderTransform = transform;

            PlaneProjection projection = new PlaneProjection();
            projection.GlobalOffsetX = -1 * centerDelta.X;
            projection.GlobalOffsetY = -1 * centerDelta.Y;
            element.Projection = projection;

            element.ManipulationDelta += TiltEffect_ManipulationDelta;
            element.ManipulationCompleted += TiltEffect_ManipulationCompleted;

            return true;
        }
开发者ID:nbclark,项目名称:commuter,代码行数:31,代码来源:TiltEffect.cs


示例16: Exit

                public void Exit(System.Action onCompleted) {
                    storyboard.Stop();
                    storyboard.Children.Clear();

                    //exit animation
                    var projection = new PlaneProjection { CenterOfRotationY = 0.1 };
                    viewContainer.Projection = projection;
                    AddDoubleAnimation(projection, "RotationX", from:0, to:90, ms:250);
                    AddDoubleAnimation(maskingLayer, "Opacity", from:1, to:0, ms:350);

                    EventHandler handler = null;
                    handler = (o, e) => {
                        storyboard.Completed -= handler;
                        onCompleted();
                        currentPlacement = null;
                    };
                    storyboard.Completed += handler;
                    storyboard.Begin();
                }
开发者ID:karbazol,项目名称:FBReaderCS,代码行数:19,代码来源:WindowManager.cs


示例17: Enter

                public void Enter(ElementPlacement initialPlacement) {
                    currentPlacement = initialPlacement;

                    //size
                    maskingLayer.Width = currentPlacement.Size.Width;
                    maskingLayer.Height = currentPlacement.Size.Height;

                    //position and orientation
                    maskingLayer.RenderTransform = currentPlacement.Transform;

                    //enter animation
                    var projection = new PlaneProjection { CenterOfRotationY = 0.1 };
                    viewContainer.Projection = projection;
                    AddDoubleAnimation(projection, "RotationX", from:-90, to:0, ms:400);
                    AddDoubleAnimation(maskingLayer, "Opacity", from:0, to:1, ms:400);

                    storyboard.Begin();
                }
开发者ID:karbazol,项目名称:FBReaderCS,代码行数:18,代码来源:WindowManager.cs


示例18: MeasureOverride

        protected override Size MeasureOverride(Size availableSize)
        {
            var newelements = (from element in Children
                               join existing in elements on element equals existing into joined
                               from item in joined.DefaultIfEmpty()
                               where item == null
                               select element).ToList();

            var oldelements = (from element in elements
                               join current in Children on element equals current into joined
                               from item in joined.DefaultIfEmpty()
                               where item == null
                               select element).ToList();

            newelements.ForEach((element) =>
                {
                    PlaneProjection projection = element.Projection as PlaneProjection;
                    if (projection == null)
                    {
                        projection = new PlaneProjection();
                        element.Projection = projection;
                    }
                });
            elements.AddRange(newelements);
            oldelements.ForEach((element) => { elements.Remove(element); });
            foreach (var item in Children)
            {
                item.Measure(availableSize);
            }
            if (double.IsPositiveInfinity(availableSize.Width) || double.IsPositiveInfinity(availableSize.Height))
            {
                return new Size(1000000, 1000000);
            }
            else
            {
                return availableSize;
            }
        }
开发者ID:JimLynn,项目名称:MessageCloud,代码行数:38,代码来源:Panel3D.cs


示例19: OnTiltChanged

        private static void OnTiltChanged(DependencyObject d,
      DependencyPropertyChangedEventArgs args)
        {
            FrameworkElement targetElement = d as FrameworkElement;

              double tiltFactor = GetTilt(d);

              // create the required transformations
              var projection = new PlaneProjection();
              var scale = new ScaleTransform();
              var translate = new TranslateTransform();

              var transGroup = new TransformGroup();
              transGroup.Children.Add(scale);
              transGroup.Children.Add(translate);

              // associate with the target element
              targetElement.Projection = projection;
              targetElement.RenderTransform = transGroup;
              targetElement.RenderTransformOrigin = new Point(0.5, 0.5);

              targetElement.MouseLeftButtonDown += (s, e) =>
            {
              var clickPosition = e.GetPosition(targetElement);

              // find the maximum of width / height
              double maxDimension = Math.Max(targetElement.ActualWidth, targetElement.ActualHeight);

              // compute the normalised horizontal distance from the centre
              double distanceFromCenterX = targetElement.ActualWidth / 2 - clickPosition.X;
              double normalisedDistanceX = 2 * distanceFromCenterX / maxDimension;

              // rotate around the Y axis
              projection.RotationY = normalisedDistanceX * TiltAngleFactor * tiltFactor;

              // compute the normalised vertical distance from the centre
              double distanceFromCenterY = targetElement.ActualHeight / 2 - clickPosition.Y;
              double normalisedDistanceY = 2 * distanceFromCenterY / maxDimension;

              // rotate around the X axis,
              projection.RotationX = -normalisedDistanceY * TiltAngleFactor * tiltFactor;

              // find the distance to centre
              double distanceToCentre = Math.Sqrt(normalisedDistanceX * normalisedDistanceX
            + normalisedDistanceY * normalisedDistanceY);

              // scale accordingly
              double scaleVal = tiltFactor * (1 - distanceToCentre) / ScaleFactor;
              scale.ScaleX = 1 - scaleVal;
              scale.ScaleY = 1 - scaleVal;

              // offset the plane transform
              var rootElement = Application.Current.RootVisual as FrameworkElement;
              var relativeToCentre = (targetElement.GetRelativePosition(rootElement).Y - rootElement.ActualHeight / 2) / 2;
              translate.Y = -relativeToCentre;
              projection.LocalOffsetY = +relativeToCentre;

            };

              targetElement.ManipulationCompleted += (s, e) =>
            {
              var sb = new Storyboard();
              sb.Children.Add(CreateAnimation(null, 0, 0.1, "RotationY", projection));
              sb.Children.Add(CreateAnimation(null, 0, 0.1, "RotationX", projection));
              sb.Children.Add(CreateAnimation(null, 1, 0.1, "ScaleX", scale));
              sb.Children.Add(CreateAnimation(null, 1, 0.1, "ScaleY", scale));
              sb.Begin();

              translate.Y = 0;
              projection.LocalOffsetY = 0;
            };
        }
开发者ID:Kelin-Hong,项目名称:JobHub_WP,代码行数:72,代码来源:MetroInMotion.cs


示例20: EaseValue

        public static void EaseValue(PlaneProjection current, PlaneProjection startValue, PlaneProjection endValue, double percent)
        {
            if (current.RotationX != endValue.RotationX) current.RotationX = EaseHelper.EaseValue(startValue.RotationX, endValue.RotationX, percent);
            if (current.RotationY != endValue.RotationY) current.RotationY = EaseHelper.EaseValue(startValue.RotationY, endValue.RotationY, percent);
            if (current.RotationZ != endValue.RotationZ) current.RotationZ = EaseHelper.EaseValue(startValue.RotationZ, endValue.RotationZ, percent);
            if (current.LocalOffsetX != endValue.LocalOffsetX) current.LocalOffsetX = EaseHelper.EaseValue(startValue.LocalOffsetX, endValue.LocalOffsetX, percent);
            if (current.LocalOffsetY != endValue.LocalOffsetY) current.LocalOffsetY = EaseHelper.EaseValue(startValue.LocalOffsetY, endValue.LocalOffsetY, percent);
            if (current.LocalOffsetZ != endValue.LocalOffsetZ) current.LocalOffsetZ = EaseHelper.EaseValue(startValue.LocalOffsetZ, endValue.LocalOffsetZ, percent);
            if (current.GlobalOffsetX != endValue.GlobalOffsetX) current.GlobalOffsetX = EaseHelper.EaseValue(startValue.GlobalOffsetX, endValue.GlobalOffsetX, percent);
            if (current.GlobalOffsetY != endValue.GlobalOffsetY) current.GlobalOffsetY = EaseHelper.EaseValue(startValue.GlobalOffsetY, endValue.GlobalOffsetY, percent);
            if (current.GlobalOffsetZ != endValue.GlobalOffsetZ) current.GlobalOffsetZ = EaseHelper.EaseValue(startValue.GlobalOffsetZ, endValue.GlobalOffsetZ, percent);
            if (current.CenterOfRotationX != endValue.CenterOfRotationX) current.CenterOfRotationX = EaseHelper.EaseValue(startValue.CenterOfRotationX, endValue.CenterOfRotationX, percent);
            if (current.CenterOfRotationY != endValue.CenterOfRotationY) current.CenterOfRotationY = EaseHelper.EaseValue(startValue.CenterOfRotationY, endValue.CenterOfRotationY, percent);
            if (current.CenterOfRotationZ != endValue.CenterOfRotationZ) current.CenterOfRotationZ = EaseHelper.EaseValue(startValue.CenterOfRotationZ, endValue.CenterOfRotationZ, percent);

            //  NOT TEST
            //if (current.ProjectionMatrix != endValue.ProjectionMatrix) EaseValue(current.ProjectionMatrix, startValue.ProjectionMatrix, endValue.ProjectionMatrix, percent);
        }
开发者ID:goeran,项目名称:ArtefactAnimator.Metro,代码行数:18,代码来源:Extras.cs



注:本文中的PlaneProjection类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C# Planet类代码示例发布时间:2022-05-24
下一篇:
C# Plane类代码示例发布时间:2022-05-24
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap