//called when data for any output pin is requested
        public void Evaluate(int SpreadMax)
        {
            if (FSampleIn.IsChanged)
            {
                FSample    = new GrainWaveProvider(FSampleIn[0]);
                FOutput[0] = FSample;
            }

            if (FSizeIn.IsChanged)
            {
                FSample.FGrain.Length = FSizeIn[0];
            }

            if (FOffsetIn.IsChanged)
            {
                FSample.FGrain.Start = (int)(FOffsetIn[0] * FSample.Length);
            }

            if (FFreqIn.IsChanged)
            {
                FSample.FGrain.Freq = FFreqIn[0];
            }
        }
		//called when data for any output pin is requested
		public void Evaluate(int SpreadMax)
		{
			if(FSampleIn.IsChanged)
			{
				FSample = new GrainWaveProvider(FSampleIn[0]);
				FOutput[0] = FSample;
			}
			
			if(FSizeIn.IsChanged)
			{
				FSample.FGrain.Length = FSizeIn[0];
			}
			
			if(FOffsetIn.IsChanged)
			{
				FSample.FGrain.Start = (int)(FOffsetIn[0] * FSample.Length);
			}
			
			if(FFreqIn.IsChanged)
			{
				FSample.FGrain.Freq = FFreqIn[0];
			}
		}