modules/audio_processing/gain_control_impl.cc
// Read chunks of data that were received and queued on the render side from
// a queue. All the data chunks are buffered into the farend signal of the AGC.
Read chunks of data that were received and queued on the render side from
a queue. All the data chunks are buffered into the farend signal of the AGC.
Read chunks of data that were received and queued on the render side from a queue . All the data chunks are buffered into the farend signal of the AGC .
void GainControlImpl::ReadQueuedRenderData() {
  if (!is_component_enabled()) {
    return;
  }
  while (render_signal_queue_->Remove(&capture_queue_buffer_)) {
    int buffer_index = 0;
    const int num_frames_per_band =
        capture_queue_buffer_.size() / num_handles();
    for (int i = 0; i < num_handles(); i++) {
      Handle* my_handle = static_cast<Handle*>(handle(i));
      WebRtcAgc_AddFarend(my_handle, &capture_queue_buffer_[buffer_index],
                          num_frames_per_band);
      buffer_index += num_frames_per_band;
    }
  }
}
void GainControlImpl :: ReadQueuedRenderData ( ) { if ( ! is_component_enabled ( ) ) { return ; } while ( render_signal_queue_ -> Remove ( & capture_queue_buffer_ ) ) { int buffer_index = 0 ; const int num_frames_per_band = capture_queue_buffer_ . size ( ) / num_handles ( ) ; for ( int i = 0 ; i < num_handles ( ) ; i ++ ) { Handle * my_handle = static_cast < Handle * > ( handle ( i ) ) ; WebRtcAgc_AddFarend ( my_handle , & capture_queue_buffer_ [ buffer_index ] , num_frames_per_band ) ; buffer_index += num_frames_per_band ; } } }
Read chunks of data that were received and queued on the render side from
a queue.
Read chunks of data that were received and queued on the render side from a queue .