コード例 #1
0
 private void Input_DataAvailable(object sender, WaveInEventArgs e)
 {
     TotalTime           = DateTime.Now.Subtract(_startRecording);
     TotalBytesRecorded += e.BytesRecorded;
     AudioRecording.AddData(e.Buffer, 0, e.BytesRecorded);
     BytesAvailable?.Invoke(sender, e);
 }
コード例 #2
0
 /// <summary>
 /// Passes callback pointers to OnDataAvailable events to the class that implements the ProcessData method,
 /// so that the appropriate events can be fired once the data has been processed.
 /// </summary>
 /// <param name="data">Delegate to the OnDataAvailable event that will be fired</param>
 /// <param name="bytes">Delegate to the OnBytesAvaialable event that will be fired</param>
 public abstract void AddEventCallbacks(DataAvailabe data, BytesAvailable bytes);
コード例 #3
0
 public override void AddEventCallbacks(DataAvailabe data, BytesAvailable bytes)
 {
     DataAvailableCallback  = data;
     BytesAvailableCallback = bytes;
 }