protected override void OnUpdateFrame(FrameEventArgs e)
        {
            spectrumData = FixDiscontinuities(Analyzer.GetSpectrum());

            spectrumData = WaveTools.LoopProm(spectrumData, 1, 2);

            for (int i = 0; i < Waves.Length; i++)
            {
                if (Replay.IsNullSpectrum(i))
                {
                    continue;
                }

                Waves[i].SpectrumData = WaveTools.CombineWaves(WaveTools.LoopProm(Replay.GetSpectrumReplay(i), Waves[i].BarsInfluence, Waves[i].PromLoops), Replay.GetSpectrumReplay(i), Waves[i].Increment);
                Waves[i].UpdatePoints(Width / 2, Height / 2, Height / 4 + power);
            }

            Replay.PushSpectrum(spectrumData);

            CalculateWavePower();

            Radius = Height / 4 + power;

            base.OnUpdateFrame(e);
        }
        public void UpdatePoints(float x, float y, float circleRadius)
        {
            if (SpectrumData == null)
            {
                return;
            }

            CatmullRomPoints.Clear();

            for (int i = 0; i < SpectrumData.Count - 1; i++)
            {
                p1 = GetPosition(x, y, WaveTools.Clamp(0, SpectrumData.Count, i - 1), circleRadius);

                p2 = GetPosition(x, y, i, circleRadius);
                p3 = GetPosition(x, y, i + 1, circleRadius);

                p4 = GetPosition(x, y, WaveTools.Clamp(0, SpectrumData.Count - 1, i + 2), circleRadius);

                for (float j = 0f; j <= 1; j += qualityIncrement)
                {
                    CatmullRomPoints.Add(WaveTools.CatmullRom(j, p1, p2, p3, p4));
                }
            }
        }