Index: webrtc/modules/rtp_rtcp/source/receive_statistics_impl.h |
diff --git a/webrtc/modules/rtp_rtcp/source/receive_statistics_impl.h b/webrtc/modules/rtp_rtcp/source/receive_statistics_impl.h |
index 913f3b5041990d0aa409371c0dced0d21a4fa275..39679673d08f8a5864b2f21a52d7e51cf19fd943 100644 |
--- a/webrtc/modules/rtp_rtcp/source/receive_statistics_impl.h |
+++ b/webrtc/modules/rtp_rtcp/source/receive_statistics_impl.h |
@@ -17,7 +17,7 @@ |
#include <map> |
#include "webrtc/base/criticalsection.h" |
-#include "webrtc/base/rate_statistics.h" |
+#include "webrtc/modules/rtp_rtcp/source/bitrate.h" |
#include "webrtc/system_wrappers/include/ntp_time.h" |
namespace webrtc { |
@@ -44,6 +44,7 @@ |
bool retransmitted); |
void FecPacketReceived(const RTPHeader& header, size_t packet_length); |
void SetMaxReorderingThreshold(int max_reordering_threshold); |
+ void ProcessBitrate(); |
virtual void LastReceiveTimeNtp(uint32_t* secs, uint32_t* frac) const; |
private: |
@@ -56,9 +57,9 @@ |
void NotifyRtpCallback() LOCKS_EXCLUDED(stream_lock_); |
void NotifyRtcpCallback() LOCKS_EXCLUDED(stream_lock_); |
- Clock* const clock_; |
+ Clock* clock_; |
rtc::CriticalSection stream_lock_; |
- RateStatistics incoming_bitrate_; |
+ Bitrate incoming_bitrate_; |
uint32_t ssrc_; |
int max_reordering_threshold_; // In number of packets or sequence numbers. |
@@ -107,6 +108,10 @@ |
StreamStatistician* GetStatistician(uint32_t ssrc) const override; |
void SetMaxReorderingThreshold(int max_reordering_threshold) override; |
+ // Implement Module. |
+ void Process() override; |
+ int64_t TimeUntilNextProcess() override; |
+ |
void RegisterRtcpStatisticsCallback( |
RtcpStatisticsCallback* callback) override; |
@@ -122,8 +127,9 @@ |
typedef std::map<uint32_t, StreamStatisticianImpl*> StatisticianImplMap; |
- Clock* const clock_; |
+ Clock* clock_; |
rtc::CriticalSection receive_statistics_lock_; |
+ int64_t last_rate_update_ms_; |
StatisticianImplMap statisticians_; |
RtcpStatisticsCallback* rtcp_stats_callback_; |