private void Wasapi_DataAvailable(object sender, DataAvailableEventArgs e) { beatDetector.ProcessBuffer(e.Data, e.ByteCount); }