示例#1
0
        private void FftProv_FftFinished(object sender, FFT.FourierEventArgs e)
        {
            Dispatcher.BeginInvoke(new Action(() => ProgressB.Value = mfr.CurrentTime.TotalMilliseconds));

            if (mfr.CurrentTime.TotalSeconds >= cparam.Begining)
            {
                CurrentComplexes.Enqueue(e.Samples);

                if (CurrentComplexes.Count > CalcRate)
                {
                    System.Numerics.Complex[][] Samples = new System.Numerics.Complex[CalcRate][];
                    for (int i = 0; CalcRate > i; i++)
                    {
                        Samples[i] = CurrentComplexes.Dequeue();
                    }

                    if (cparam.UsingLowPass)
                    {
                        ComputeFFTInLowPassMode(Samples);
                    }
                    else
                    {
                        ComputeFFTInDifferencesMode(Samples);
                    }

                    CurrentComplexes.Clear();
                }
            }
        }
示例#2
0
 private void Fft_FftFinished(object sender, FFT.FourierEventArgs e)
 {
     FftFinished?.Invoke(this, e);
 }