Add statistics gathering for packet loss.

Adds a class used to classify whether packet loss events are a single packet or multiple packets as well as how many packets have been lost. Also exposes a new function in the RtpRtcp interface to retrieve these statistics.

BUG=

Review URL: https://codereview.webrtc.org/1198853004

Cr-Commit-Position: refs/heads/master@{#9568}
This commit is contained in:
bcornell
2015-07-10 18:10:05 -07:00
committed by Commit bot
parent 35b72fbceb
commit 30409b4dca
11 changed files with 459 additions and 0 deletions

View File

@ -350,5 +350,18 @@ class NullRtpAudioFeedback : public RtpAudioFeedback {
const uint8_t volume) override {}
};
// Statistics about packet loss for a single directional connection. All values
// are totals since the connection initiated.
struct RtpPacketLossStats {
// The number of packets lost in events where no adjacent packets were also
// lost.
uint64_t single_packet_loss_count;
// The number of events in which more than one adjacent packet was lost.
uint64_t multiple_packet_loss_event_count;
// The number of packets lost in events where more than one adjacent packet
// was lost.
uint64_t multiple_packet_loss_packet_count;
};
} // namespace webrtc
#endif // WEBRTC_MODULES_RTP_RTCP_INTERFACE_RTP_RTCP_DEFINES_H_