private void button1_Click(object sender, EventArgs e) { detector.loadSystem(); //electronic music most of the time needs a sample size of 2048 //music like rage against the machine works best with a sample size of 256 but still barely works detector.LoadSong(256, "ratm.mp3"); reporter = BeatReporter.GetReporterInstance(detector); Console.WriteLine("Instance initialized and loaded!"); }
public static BeatReporter GetReporterInstance(BeatDetector detector) { return(myself ?? (myself = new BeatReporter(detector))); }