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

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

Issue 2405403003: Add empty residual echo detector. (Closed)
Patch Set: Addressed reviewer comments. Created 4 years, 2 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_detector/echo_detector.h
diff --git a/webrtc/test/fuzzers/sdp_parser_fuzzer.cc b/webrtc/modules/audio_processing/echo_detector/echo_detector.h
similarity index 51%
copy from webrtc/test/fuzzers/sdp_parser_fuzzer.cc
copy to webrtc/modules/audio_processing/echo_detector/echo_detector.h
index f21c991a3e1da9983514f636400e22cf9c989c9d..fd190834329cc1760208f0efd7349ab62e84fc62 100644
--- a/webrtc/test/fuzzers/sdp_parser_fuzzer.cc
+++ b/webrtc/modules/audio_processing/echo_detector/echo_detector.h
@@ -8,18 +8,25 @@
* be found in the AUTHORS file in the root of the source tree.
*/
-#include <stddef.h>
-#include <stdint.h>
+#ifndef WEBRTC_MODULES_AUDIO_PROCESSING_ECHO_DETECTOR_ECHO_DETECTOR_H_
+#define WEBRTC_MODULES_AUDIO_PROCESSING_ECHO_DETECTOR_ECHO_DETECTOR_H_
-#include "webrtc/api/jsepsessiondescription.h"
+#include <stddef.h>
namespace webrtc {
-void FuzzOneInput(const uint8_t* data, size_t size) {
- std::string message(reinterpret_cast<const char*>(data), size);
- webrtc::SdpParseError error;
- std::unique_ptr<webrtc::SessionDescriptionInterface> sdp(
- CreateSessionDescription("offer", message, &error));
-}
+class EchoDetector {
+ public:
+ EchoDetector() {}
+ ~EchoDetector() {}
+
+ void BufferFarend(const float* farend, size_t num_samples);
hlundin-webrtc 2016/10/14 07:15:52 I think you should use rtc::ArrayView<const float>
kwiberg-webrtc 2016/10/14 07:28:48 +1. ArrayView should be used instead of separate p
ivoc 2016/10/14 09:53:19 Done.
+
+ void Process(const float* nearend, size_t num_samples);
hlundin-webrtc 2016/10/14 07:15:53 And here.
ivoc 2016/10/14 09:53:18 Done.
+
+ void Initialize(int sample_rate_hz);
+};
} // namespace webrtc
+
+#endif // WEBRTC_MODULES_AUDIO_PROCESSING_ECHO_DETECTOR_ECHO_DETECTOR_H_

Powered by Google App Engine
This is Rietveld 408576698