Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(897)

Unified Diff: webrtc/modules/audio_processing/echo_cancellation_impl.h

Issue 1770823002: Removed the AudioProcessing dependency in EchoCancellerImpl (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@CleanUpAecImpl_CL
Patch Set: Changed the way the error checks were done Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: webrtc/modules/audio_processing/echo_cancellation_impl.h
diff --git a/webrtc/modules/audio_processing/echo_cancellation_impl.h b/webrtc/modules/audio_processing/echo_cancellation_impl.h
index ff7c3ae319eb67eb603504f53f8709b4278cbef8..4669d3d0afbbf75c4141f3e2142a1d77bb8b69c5 100644
--- a/webrtc/modules/audio_processing/echo_cancellation_impl.h
+++ b/webrtc/modules/audio_processing/echo_cancellation_impl.h
@@ -31,7 +31,7 @@ class EchoCancellationImpl : public EchoCancellation {
virtual ~EchoCancellationImpl();
int ProcessRenderAudio(const AudioBuffer* audio);
- int ProcessCaptureAudio(AudioBuffer* audio);
+ int ProcessCaptureAudio(AudioBuffer* audio, int stream_delay_ms);
// EchoCancellation implementation.
bool is_enabled() const override;
@@ -40,6 +40,10 @@ class EchoCancellationImpl : public EchoCancellation {
bool is_drift_compensation_enabled() const override;
void Initialize();
+ void Initialize(int sample_rate_hz,
+ size_t num_reverse_channels_,
+ size_t num_output_channels_,
+ size_t num_proc_channels_);
void SetExtraOptions(const Config& config);
bool is_delay_agnostic_enabled() const;
bool is_extended_filter_enabled() const;
@@ -54,6 +58,7 @@ class EchoCancellationImpl : public EchoCancellation {
private:
class Canceller;
+ struct StreamProperties;
// EchoCancellation implementation.
int Enable(bool enable) override;
@@ -73,13 +78,16 @@ class EchoCancellationImpl : public EchoCancellation {
struct AecCore* aec_core() const override;
- size_t num_handles_required() const;
+ size_t NumCancellersRequired() const;
void AllocateRenderQueue();
int Configure();
// Not guarded as its public API is thread safe.
const AudioProcessing* apm_;
+ size_t num_reverse_channels_;
+ size_t num_output_channels_;
+ size_t num_proc_channels_;
rtc::CriticalSection* const crit_render_ ACQUIRED_BEFORE(crit_capture_);
rtc::CriticalSection* const crit_capture_;
@@ -106,6 +114,8 @@ class EchoCancellationImpl : public EchoCancellation {
render_signal_queue_;
std::vector<std::unique_ptr<Canceller>> cancellers_;
+ std::unique_ptr<StreamProperties> stream_properties_;
+
RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(EchoCancellationImpl);
};

Powered by Google App Engine
This is Rietveld 408576698