Esempio n. 1
0
 public override object ConstructObject()
 {
     if (FRoot[this.CurrObj] is VObjectCollection)
     {
         VObjectCollection vc     = FRoot[this.CurrObj] as VObjectCollection;
         Smoothing         NewObj = new Smoothing(FHDEHost, FVPath[this.CurrObj], FVPathSep[this.CurrObj], vc);
         NewObj.Algorithm  = FAlgorithm[this.CurrObj];
         NewObj.FilterTime = FFilterTime[this.CurrObj];
         return(NewObj);
     }
     else
     {
         return(null);
     }
 }
Esempio n. 2
0
 public void Evaluate(int SpreadMax)
 {
     if (FInput.IsConnected)
     {
         FCurrent.SliceCount = 0;
         FTarget.SliceCount  = 0;
         for (int i = 0; i < FInput.SliceCount; i++)
         {
             if (FInput[i] is Smoothing)
             {
                 Smoothing Content = FInput[i] as Smoothing;
                 for (int j = 0; j < Content.CurrentValues.Count; j++)
                 {
                     for (int k = 0; k < Content.CurrentValues[j].Count; k++)
                     {
                         if (Content.TargetValues[j][k] is double)
                         {
                             FTarget.Add((double)Content.TargetValues[j][k]);
                             FCurrent.Add(Content.CurrentValues[j][k]);
                         }
                         if (Content.TargetValues[j][k] is float)
                         {
                             FTarget.Add((float)Content.TargetValues[j][k]);
                             FCurrent.Add(Content.CurrentValues[j][k]);
                         }
                     }
                 }
                 if (FSet[i])
                 {
                     Content.FilterTime = FFilterTime[i];
                 }
                 if (FReset[i])
                 {
                     Content.CheckPath();
                 }
             }
         }
     }
     else
     {
         FCurrent.SliceCount = 0;
         FTarget.SliceCount  = 0;
     }
 }