OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2013 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2013 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 901 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
912 // TODO(solenberg): Some test cases in EndToEndTest use this from a different | 912 // TODO(solenberg): Some test cases in EndToEndTest use this from a different |
913 // thread. Re-enable once that is fixed. | 913 // thread. Re-enable once that is fixed. |
914 // RTC_DCHECK_CALLED_SEQUENTIALLY(&configuration_sequence_checker_); | 914 // RTC_DCHECK_CALLED_SEQUENTIALLY(&configuration_sequence_checker_); |
915 Stats stats; | 915 Stats stats; |
916 // Fetch available send/receive bitrates. | 916 // Fetch available send/receive bitrates. |
917 uint32_t send_bandwidth = 0; | 917 uint32_t send_bandwidth = 0; |
918 transport_send_->send_side_cc()->GetBitrateController()->AvailableBandwidth( | 918 transport_send_->send_side_cc()->GetBitrateController()->AvailableBandwidth( |
919 &send_bandwidth); | 919 &send_bandwidth); |
920 std::vector<unsigned int> ssrcs; | 920 std::vector<unsigned int> ssrcs; |
921 uint32_t recv_bandwidth = 0; | 921 uint32_t recv_bandwidth = 0; |
| 922 |
| 923 // TODO(nisse): Is this thread safe? Most access to |receive_side_cc_| is done |
| 924 // via |*_rtp_transport_receive_|, and protected by |receive_crit_|. |
922 receive_side_cc_.GetRemoteBitrateEstimator(false)->LatestEstimate( | 925 receive_side_cc_.GetRemoteBitrateEstimator(false)->LatestEstimate( |
923 &ssrcs, &recv_bandwidth); | 926 &ssrcs, &recv_bandwidth); |
924 stats.send_bandwidth_bps = send_bandwidth; | 927 stats.send_bandwidth_bps = send_bandwidth; |
925 stats.recv_bandwidth_bps = recv_bandwidth; | 928 stats.recv_bandwidth_bps = recv_bandwidth; |
926 stats.pacer_delay_ms = | 929 stats.pacer_delay_ms = |
927 transport_send_->send_side_cc()->GetPacerQueuingDelayMs(); | 930 transport_send_->send_side_cc()->GetPacerQueuingDelayMs(); |
928 stats.rtt_ms = call_stats_->rtcp_rtt_stats()->LastProcessedRtt(); | 931 stats.rtt_ms = call_stats_->rtcp_rtt_stats()->LastProcessedRtt(); |
929 { | 932 { |
930 rtc::CritScope cs(&bitrate_crit_); | 933 rtc::CritScope cs(&bitrate_crit_); |
931 stats.max_padding_bitrate_bps = configured_max_padding_bitrate_bps_; | 934 stats.max_padding_bitrate_bps = configured_max_padding_bitrate_bps_; |
(...skipping 503 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1435 (use_send_side_bwe && header.extension.hasTransportSequenceNumber)) { | 1438 (use_send_side_bwe && header.extension.hasTransportSequenceNumber)) { |
1436 receive_side_cc_.OnReceivedPacket( | 1439 receive_side_cc_.OnReceivedPacket( |
1437 packet.arrival_time_ms(), packet.payload_size() + packet.padding_size(), | 1440 packet.arrival_time_ms(), packet.payload_size() + packet.padding_size(), |
1438 header); | 1441 header); |
1439 } | 1442 } |
1440 } | 1443 } |
1441 | 1444 |
1442 } // namespace internal | 1445 } // namespace internal |
1443 | 1446 |
1444 } // namespace webrtc | 1447 } // namespace webrtc |
OLD | NEW |