Delete RtpRtcp::RemoteRTCPStat in favor of GetLatestReportBlockData
Bug: webrtc:10678 Change-Id: I1cff0230208e22f56f26cf2eba976f66d9b5bafc Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/212020 Reviewed-by: Henrik Boström <hbos@webrtc.org> Commit-Queue: Danil Chapovalov <danilchap@webrtc.org> Cr-Commit-Position: refs/heads/master@{#33479}
This commit is contained in:
committed by
Commit Bot
parent
19775cbd29
commit
ab63350411
@ -123,20 +123,18 @@ void ModuleRtpRtcpImpl::Process() {
|
||||
// processed RTT for at least |kRtpRtcpRttProcessTimeMs| milliseconds.
|
||||
// Note that LastReceivedReportBlockMs() grabs a lock, so check
|
||||
// |process_rtt| first.
|
||||
if (process_rtt &&
|
||||
if (process_rtt && rtt_stats_ != nullptr &&
|
||||
rtcp_receiver_.LastReceivedReportBlockMs() > last_rtt_process_time_) {
|
||||
std::vector<RTCPReportBlock> receive_blocks;
|
||||
rtcp_receiver_.StatisticsReceived(&receive_blocks);
|
||||
int64_t max_rtt = 0;
|
||||
for (std::vector<RTCPReportBlock>::iterator it = receive_blocks.begin();
|
||||
it != receive_blocks.end(); ++it) {
|
||||
int64_t rtt = 0;
|
||||
rtcp_receiver_.RTT(it->sender_ssrc, &rtt, NULL, NULL, NULL);
|
||||
max_rtt = (rtt > max_rtt) ? rtt : max_rtt;
|
||||
int64_t max_rtt_ms = 0;
|
||||
for (const auto& block : rtcp_receiver_.GetLatestReportBlockData()) {
|
||||
if (block.last_rtt_ms() > max_rtt_ms) {
|
||||
max_rtt_ms = block.last_rtt_ms();
|
||||
}
|
||||
}
|
||||
// Report the rtt.
|
||||
if (rtt_stats_ && max_rtt != 0)
|
||||
rtt_stats_->OnRttUpdate(max_rtt);
|
||||
if (max_rtt_ms > 0) {
|
||||
rtt_stats_->OnRttUpdate(max_rtt_ms);
|
||||
}
|
||||
}
|
||||
|
||||
// Verify receiver reports are delivered and the reported sequence number
|
||||
@ -536,11 +534,6 @@ void ModuleRtpRtcpImpl::GetSendStreamDataCounters(
|
||||
}
|
||||
|
||||
// Received RTCP report.
|
||||
int32_t ModuleRtpRtcpImpl::RemoteRTCPStat(
|
||||
std::vector<RTCPReportBlock>* receive_blocks) const {
|
||||
return rtcp_receiver_.StatisticsReceived(receive_blocks);
|
||||
}
|
||||
|
||||
std::vector<ReportBlockData> ModuleRtpRtcpImpl::GetLatestReportBlockData()
|
||||
const {
|
||||
return rtcp_receiver_.GetLatestReportBlockData();
|
||||
|
||||
Reference in New Issue
Block a user