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

Side by Side Diff: webrtc/modules/remote_bitrate_estimator/test/estimators/nada.cc

Issue 1736663004: Revert of Remove ignored return code from modules. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2015 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2015 The WebRTC project authors. All Rights Reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 * 9 *
10 */ 10 */
(...skipping 220 matching lines...) Expand 10 before | Expand all | Expand 10 after
231 bitrate_kbps_ = std::min(bitrate_kbps_, kMaxBitrateKbps); 231 bitrate_kbps_ = std::min(bitrate_kbps_, kMaxBitrateKbps);
232 bitrate_kbps_ = std::max(bitrate_kbps_, kMinBitrateKbps); 232 bitrate_kbps_ = std::max(bitrate_kbps_, kMinBitrateKbps);
233 233
234 observer_->OnNetworkChanged(1000 * bitrate_kbps_, 0, rtt_ms); 234 observer_->OnNetworkChanged(1000 * bitrate_kbps_, 0, rtt_ms);
235 } 235 }
236 236
237 int64_t NadaBweSender::TimeUntilNextProcess() { 237 int64_t NadaBweSender::TimeUntilNextProcess() {
238 return 100; 238 return 100;
239 } 239 }
240 240
241 void NadaBweSender::Process() { 241 int NadaBweSender::Process() {
242 return 0;
242 } 243 }
243 244
244 void NadaBweSender::AcceleratedRampUp(const NadaFeedback& fb) { 245 void NadaBweSender::AcceleratedRampUp(const NadaFeedback& fb) {
245 const int kMaxRampUpQueuingDelayMs = 50; // Referred as T_th. 246 const int kMaxRampUpQueuingDelayMs = 50; // Referred as T_th.
246 const float kGamma0 = 0.5f; // Referred as gamma_0. 247 const float kGamma0 = 0.5f; // Referred as gamma_0.
247 248
248 float gamma = 249 float gamma =
249 std::min(kGamma0, static_cast<float>(kMaxRampUpQueuingDelayMs) / 250 std::min(kGamma0, static_cast<float>(kMaxRampUpQueuingDelayMs) /
250 (min_round_trip_time_ms_ + min_feedback_delay_ms_)); 251 (min_round_trip_time_ms_ + min_feedback_delay_ms_));
251 252
(...skipping 27 matching lines...) Expand all
279 (kTheta - (bitrate_kbps_ - kMinBitrateKbps) * x_hat)) / 280 (kTheta - (bitrate_kbps_ - kMinBitrateKbps) * x_hat)) /
280 (kTauOMs * kTauOMs) + 281 (kTauOMs * kTauOMs) +
281 0.5f); 282 0.5f);
282 283
283 bitrate_kbps_ = bitrate_kbps_ + smoothing_factor * original_increase; 284 bitrate_kbps_ = bitrate_kbps_ + smoothing_factor * original_increase;
284 } 285 }
285 286
286 } // namespace bwe 287 } // namespace bwe
287 } // namespace testing 288 } // namespace testing
288 } // namespace webrtc 289 } // namespace webrtc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698