From 3e7703640fbc3c402f9ae7925dca697714ceddb9 Mon Sep 17 00:00:00 2001 From: "niklas.enbom@webrtc.org" Date: Wed, 25 Sep 2013 22:05:05 +0000 Subject: [PATCH] Remove unused constants, so chrome can enable a warning for that. Patch from thakis@ R=andrew@webrtc.org Review URL: https://webrtc-codereview.appspot.com/2296006 git-svn-id: http://webrtc.googlecode.com/svn/trunk@4844 4adac7df-926f-26a2-2b94-8c16560cd09d --- .../audio_coding/codecs/isac/fix/source/pitch_filter.c | 5 ----- webrtc/modules/audio_coding/main/acm2/acm_receiver.cc | 1 - webrtc/modules/audio_processing/aec/aec_core.c | 3 --- webrtc/modules/audio_processing/aecm/aecm_core.c | 2 ++ webrtc/modules/remote_bitrate_estimator/rtp_to_ntp.cc | 2 -- webrtc/modules/rtp_rtcp/source/rtcp_receiver.cc | 5 ----- webrtc/modules/rtp_rtcp/source/rtp_rtcp_impl.cc | 7 ------- webrtc/video_engine/vie_capturer.cc | 1 - webrtc/video_engine/vie_remb.cc | 1 - 9 files changed, 2 insertions(+), 25 deletions(-) diff --git a/webrtc/modules/audio_coding/codecs/isac/fix/source/pitch_filter.c b/webrtc/modules/audio_coding/codecs/isac/fix/source/pitch_filter.c index 89d884a0b9..df961a7a4b 100644 --- a/webrtc/modules/audio_coding/codecs/isac/fix/source/pitch_filter.c +++ b/webrtc/modules/audio_coding/codecs/isac/fix/source/pitch_filter.c @@ -27,11 +27,6 @@ static const int kSegments = 5; // A division factor of 1/5 in Q15. static const int16_t kDivFactor = 6553; -// Filter coefficicients in Q15. -static const int16_t kDampFilter[PITCH_DAMPORDER] = { - -2294, 8192, 20972, 8192, -2294 -}; - // Interpolation coefficients; generated by design_pitch_filter.m. // Coefficients are stored in Q14. static const int16_t kIntrpCoef[PITCH_FRACS][PITCH_FRACORDER] = { diff --git a/webrtc/modules/audio_coding/main/acm2/acm_receiver.cc b/webrtc/modules/audio_coding/main/acm2/acm_receiver.cc index d5acfac367..9c9f05d9b2 100644 --- a/webrtc/modules/audio_coding/main/acm2/acm_receiver.cc +++ b/webrtc/modules/audio_coding/main/acm2/acm_receiver.cc @@ -32,7 +32,6 @@ namespace webrtc { namespace { -const int kRtpHeaderSize = 12; const int kNeteqInitSampleRateHz = 16000; const int kNackThresholdPackets = 2; diff --git a/webrtc/modules/audio_processing/aec/aec_core.c b/webrtc/modules/audio_processing/aec/aec_core.c index d194c82694..deaf74aa2d 100644 --- a/webrtc/modules/audio_processing/aec/aec_core.c +++ b/webrtc/modules/audio_processing/aec/aec_core.c @@ -31,9 +31,6 @@ // Buffer size (samples) static const size_t kBufSizePartitions = 250; // 1 second of audio in 16 kHz. -// Noise suppression -static const int converged = 250; - // Metrics static const int subCountLen = 4; static const int countLen = 50; diff --git a/webrtc/modules/audio_processing/aecm/aecm_core.c b/webrtc/modules/audio_processing/aecm/aecm_core.c index db35515623..a44ce08da4 100644 --- a/webrtc/modules/audio_processing/aecm/aecm_core.c +++ b/webrtc/modules/audio_processing/aecm/aecm_core.c @@ -44,6 +44,7 @@ static const ALIGN8_BEG int16_t WebRtcAecm_kSqrtHanning[] ALIGN8_END = { }; #endif +#ifdef AECM_WITH_ABS_APPROX //Q15 alpha = 0.99439986968132 const Factor for magnitude approximation static const uint16_t kAlpha1 = 32584; //Q15 beta = 0.12967166976970 const Factor for magnitude approximation @@ -56,6 +57,7 @@ static const uint16_t kBeta2 = 11072; static const uint16_t kAlpha3 = 26951; //Q15 beta = 0.57762063060713 const Factor for magnitude approximation static const uint16_t kBeta3 = 18927; +#endif // Initialization table for echo channel in 8 kHz static const int16_t kChannelStored8kHz[PART_LEN1] = { diff --git a/webrtc/modules/remote_bitrate_estimator/rtp_to_ntp.cc b/webrtc/modules/remote_bitrate_estimator/rtp_to_ntp.cc index 5ed38c9fc5..109edae7cc 100644 --- a/webrtc/modules/remote_bitrate_estimator/rtp_to_ntp.cc +++ b/webrtc/modules/remote_bitrate_estimator/rtp_to_ntp.cc @@ -18,8 +18,6 @@ namespace webrtc { namespace synchronization { -const double kNtpFracPerMs = 4.294967296E6; - RtcpMeasurement::RtcpMeasurement() : ntp_secs(0), ntp_frac(0), rtp_timestamp(0) {} diff --git a/webrtc/modules/rtp_rtcp/source/rtcp_receiver.cc b/webrtc/modules/rtp_rtcp/source/rtcp_receiver.cc index 9ab1fb69b2..0771eba810 100644 --- a/webrtc/modules/rtp_rtcp/source/rtcp_receiver.cc +++ b/webrtc/modules/rtp_rtcp/source/rtcp_receiver.cc @@ -19,11 +19,6 @@ #include "webrtc/system_wrappers/interface/trace.h" #include "webrtc/system_wrappers/interface/trace_event.h" -namespace -{ - const float FRAC = 4.294967296E9; -} - namespace webrtc { using namespace RTCPUtility; using namespace RTCPHelp; diff --git a/webrtc/modules/rtp_rtcp/source/rtp_rtcp_impl.cc b/webrtc/modules/rtp_rtcp/source/rtp_rtcp_impl.cc index 7c4cee7e87..068b5cfe26 100644 --- a/webrtc/modules/rtp_rtcp/source/rtp_rtcp_impl.cc +++ b/webrtc/modules/rtp_rtcp/source/rtp_rtcp_impl.cc @@ -22,13 +22,6 @@ extern MatlabEngine eng; // Global variable defined elsewhere. #endif -// Local for this file. -namespace { - -const float kFracMs = 4.294967296E6f; - -} // namespace - #ifdef _WIN32 // Disable warning C4355: 'this' : used in base member initializer list. #pragma warning(disable : 4355) diff --git a/webrtc/video_engine/vie_capturer.cc b/webrtc/video_engine/vie_capturer.cc index dd0f3177b8..e380bc3a3f 100644 --- a/webrtc/video_engine/vie_capturer.cc +++ b/webrtc/video_engine/vie_capturer.cc @@ -31,7 +31,6 @@ namespace webrtc { const int kThreadWaitTimeMs = 100; -const int kMaxDeliverWaitTime = 500; ViECapturer::ViECapturer(int capture_id, int engine_id, diff --git a/webrtc/video_engine/vie_remb.cc b/webrtc/video_engine/vie_remb.cc index 578c0b4795..6b0f161d93 100644 --- a/webrtc/video_engine/vie_remb.cc +++ b/webrtc/video_engine/vie_remb.cc @@ -22,7 +22,6 @@ namespace webrtc { -const int kRembTimeOutThresholdMs = 2000; const int kRembSendIntervallMs = 1000; const unsigned int kRembMinimumBitrateKbps = 50;