| OLD | NEW |
| 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 79 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 90 switch (estimator) { | 90 switch (estimator) { |
| 91 case kRembEstimator: | 91 case kRembEstimator: |
| 92 return new RembBweSender(kbps, observer, clock); | 92 return new RembBweSender(kbps, observer, clock); |
| 93 case kSendSideEstimator: | 93 case kSendSideEstimator: |
| 94 return new SendSideBweSender(kbps, observer, clock); | 94 return new SendSideBweSender(kbps, observer, clock); |
| 95 case kNadaEstimator: | 95 case kNadaEstimator: |
| 96 return new NadaBweSender(kbps, observer, clock); | 96 return new NadaBweSender(kbps, observer, clock); |
| 97 case kBbrEstimator: | 97 case kBbrEstimator: |
| 98 return new BbrBweSender(observer, clock); | 98 return new BbrBweSender(observer, clock); |
| 99 case kTcpEstimator: | 99 case kTcpEstimator: |
| 100 RTC_FALLTHROUGH(); | 100 FALLTHROUGH(); |
| 101 case kNullEstimator: | 101 case kNullEstimator: |
| 102 return new NullBweSender(); | 102 return new NullBweSender(); |
| 103 } | 103 } |
| 104 assert(false); | 104 assert(false); |
| 105 return NULL; | 105 return NULL; |
| 106 } | 106 } |
| 107 | 107 |
| 108 BweReceiver* CreateBweReceiver(BandwidthEstimatorType type, | 108 BweReceiver* CreateBweReceiver(BandwidthEstimatorType type, |
| 109 int flow_id, | 109 int flow_id, |
| 110 bool plot) { | 110 bool plot) { |
| (...skipping 165 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 276 | 276 |
| 277 float LossAccount::LossRatio() { | 277 float LossAccount::LossRatio() { |
| 278 if (num_total == 0) | 278 if (num_total == 0) |
| 279 return 0.0f; | 279 return 0.0f; |
| 280 return static_cast<float>(num_lost) / num_total; | 280 return static_cast<float>(num_lost) / num_total; |
| 281 } | 281 } |
| 282 | 282 |
| 283 } // namespace bwe | 283 } // namespace bwe |
| 284 } // namespace testing | 284 } // namespace testing |
| 285 } // namespace webrtc | 285 } // namespace webrtc |
| OLD | NEW |