Exemplo n.º 1
0
 /// <summary>
 /// change the object style and location according to the new values.
 /// </summary>
 /// <param name="values"></param>
 public void NewSample(float values)
 {
     try
     {
         if (ChildAnimationMovingAveEnable)
         {
             values = MovingAvrage.Clock(values, ChildAnimationMovingAveLength);
         }
         if (values > 0.9f)
         {
             values = 1;
         }
         device.BeginLayerDraw(0);
         //! Select the scenario.
         curScenario.NewSample(values);
     }
     catch (Exception ex)
     {
         xPFT.Exceptions.ExceptionHandler.LogError(ex);
     }
     finally
     {
         if (device != null)
         {
             device.EndLayerDraw(0);
             device.Present();
         }
     }
 }