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

Unified Diff: webrtc/modules/audio_processing/level_controller/peak_level_estimator.h

Issue 2337083002: Reland of added functionality for specifying the initial signal level to use for the gain estimation (Closed)
Patch Set: Changed name of unit test Created 4 years, 3 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/level_controller/peak_level_estimator.h
diff --git a/webrtc/modules/audio_processing/level_controller/peak_level_estimator.h b/webrtc/modules/audio_processing/level_controller/peak_level_estimator.h
index 270bbc3ad0a1e9e7960a36892033b2ea5947d778..4ad2bd371f565004babca1588255aad6ce6377d8 100644
--- a/webrtc/modules/audio_processing/level_controller/peak_level_estimator.h
+++ b/webrtc/modules/audio_processing/level_controller/peak_level_estimator.h
@@ -12,24 +12,26 @@
#define WEBRTC_MODULES_AUDIO_PROCESSING_LEVEL_CONTROLLER_PEAK_LEVEL_ESTIMATOR_H_
#include "webrtc/base/constructormagic.h"
+#include "webrtc/base/gtest_prod_util.h"
+#include "webrtc/modules/audio_processing/level_controller/lc_constants.h"
#include "webrtc/modules/audio_processing/level_controller/signal_classifier.h"
namespace webrtc {
class PeakLevelEstimator {
public:
- PeakLevelEstimator();
+ explicit PeakLevelEstimator(float initial_peak_level_dbfs);
~PeakLevelEstimator();
- void Initialize();
+ void Initialize(float initial_peak_level_dbfs);
float Analyze(SignalClassifier::SignalType signal_type,
float frame_peak_level);
-
private:
+ FRIEND_TEST_ALL_PREFIXES(LevelControllerConfig, InitialLevel);
the sun 2016/09/30 08:51:16 Try to get by without these, please. In particular
peah-webrtc 2016/10/03 09:52:14 I don't think this is really related to the coupli
the sun 2016/10/06 07:21:13 Acknowledged.
float peak_level_;
int hold_counter_;
bool initialization_phase_;
- RTC_DISALLOW_COPY_AND_ASSIGN(PeakLevelEstimator);
+ RTC_DISALLOW_IMPLICIT_CONSTRUCTORS(PeakLevelEstimator);
};
} // namespace webrtc

Powered by Google App Engine
This is Rietveld 408576698