Exemplo n.º 1
0
        private void RunSpiro(SpiroShape shape)
        {
            if (shape == null)
            {
                return;
            }

            var bc     = new PathBezierContext();
            var result = TryToRunSpiro(shape, bc);

            if (_data.ContainsKey(shape))
            {
                _data[shape]  = result ? bc.ToString() : null;
                _knots[shape] = result ? bc.GetKnots() : null;
            }
            else
            {
                _data.Add(shape, result ? bc.ToString() : null);
                _knots.Add(shape, result ? bc.GetKnots() : null);
            }
        }
Exemplo n.º 2
0
        private void RunSpiro(SpiroShape shape)
        {
            if (shape == null)
                return;

            var bc = new PathBezierContext();
            var result = TryToRunSpiro(shape, bc);
            if (_data.ContainsKey(shape))
            {
                _data[shape] = result ? bc.ToString() : null;
                _knots[shape] = result ? bc.GetKnots() : null;
            }
            else
            {
                _data.Add(shape, result ? bc.ToString() : null);
                _knots.Add(shape, result ? bc.GetKnots() : null);
            }
        }