Delete deprecated method StreamStatistician::GetStatistics
Bug: webrtc:10679 Change-Id: I9374b390783ef557c6981d8b3cea0be71f58cd27 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/150323 Reviewed-by: Danil Chapovalov <danilchap@webrtc.org> Commit-Queue: Niels Moller <nisse@webrtc.org> Cr-Commit-Position: refs/heads/master@{#29080}
This commit is contained in:
@ -43,10 +43,6 @@ class StreamStatistician {
|
||||
|
||||
virtual RtpReceiveStats GetStats() const = 0;
|
||||
|
||||
// TODO(nisse): Delete, migrate users to the above the GetStats method.
|
||||
RTC_DEPRECATED
|
||||
virtual bool GetStatistics(RtcpStatistics* statistics, bool reset) = 0;
|
||||
|
||||
// Returns average over the stream life time.
|
||||
virtual absl::optional<int> GetFractionLostInPercent() const = 0;
|
||||
|
||||
|
@ -182,28 +182,6 @@ RtpReceiveStats StreamStatisticianImpl::GetStats() const {
|
||||
return stats;
|
||||
}
|
||||
|
||||
bool StreamStatisticianImpl::GetStatistics(RtcpStatistics* statistics,
|
||||
bool reset) {
|
||||
rtc::CritScope cs(&stream_lock_);
|
||||
if (!ReceivedRtpPacket()) {
|
||||
return false;
|
||||
}
|
||||
|
||||
if (!reset) {
|
||||
if (!ReceivedRtpPacket()) {
|
||||
// No report.
|
||||
return false;
|
||||
}
|
||||
// Just get last report.
|
||||
*statistics = last_reported_statistics_;
|
||||
return true;
|
||||
}
|
||||
|
||||
*statistics = CalculateRtcpStatistics();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
bool StreamStatisticianImpl::GetActiveStatisticsAndReset(
|
||||
RtcpStatistics* statistics) {
|
||||
rtc::CritScope cs(&stream_lock_);
|
||||
@ -250,9 +228,6 @@ RtcpStatistics StreamStatisticianImpl::CalculateRtcpStatistics() {
|
||||
// Note: internal jitter value is in Q4 and needs to be scaled by 1/16.
|
||||
stats.jitter = jitter_q4_ >> 4;
|
||||
|
||||
// Store this report.
|
||||
last_reported_statistics_ = stats;
|
||||
|
||||
// Only for report blocks in RTCP SR and RR.
|
||||
last_report_cumulative_loss_ = cumulative_loss_;
|
||||
last_report_seq_max_ = received_seq_max_;
|
||||
|
@ -33,8 +33,6 @@ class StreamStatisticianImpl : public StreamStatistician {
|
||||
|
||||
RtpReceiveStats GetStats() const override;
|
||||
|
||||
// |reset| here and in next method restarts calculation of fraction_lost stat.
|
||||
bool GetStatistics(RtcpStatistics* statistics, bool reset) override;
|
||||
bool GetActiveStatisticsAndReset(RtcpStatistics* statistics);
|
||||
absl::optional<int> GetFractionLostInPercent() const override;
|
||||
StreamDataCounters GetReceiveStreamDataCounters() const override;
|
||||
@ -99,7 +97,6 @@ class StreamStatisticianImpl : public StreamStatistician {
|
||||
// Counter values when we sent the last report.
|
||||
int32_t last_report_cumulative_loss_ RTC_GUARDED_BY(&stream_lock_);
|
||||
int64_t last_report_seq_max_ RTC_GUARDED_BY(&stream_lock_);
|
||||
RtcpStatistics last_reported_statistics_ RTC_GUARDED_BY(&stream_lock_);
|
||||
};
|
||||
|
||||
class ReceiveStatisticsImpl : public ReceiveStatistics {
|
||||
|
Reference in New Issue
Block a user