Adds maximum burst length to InterArrival class.
This restricts the maximum burst length to receive times 100 ms apart.
Currently packets will be considered part of the same burst as long as
they are received within 5 ms from the previous packet. This can happen
when recovering from large network buffers.
Bug: webrtc:9718
Change-Id: I73027ddaae922cb7bb9a477cf29b4f0036ce6966
Reviewed-on: https://webrtc-review.googlesource.com/98280
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Stefan Holmer <stefan@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24601}diff --git a/modules/remote_bitrate_estimator/inter_arrival.h b/modules/remote_bitrate_estimator/inter_arrival.h
index f46bf44..f2facd4 100644
--- a/modules/remote_bitrate_estimator/inter_arrival.h
+++ b/modules/remote_bitrate_estimator/inter_arrival.h
@@ -54,13 +54,18 @@
private:
struct TimestampGroup {
TimestampGroup()
- : size(0), first_timestamp(0), timestamp(0), complete_time_ms(-1) {}
+ : size(0),
+ first_timestamp(0),
+ timestamp(0),
+ first_arrival_ms(-1),
+ complete_time_ms(-1) {}
bool IsFirstPacket() const { return complete_time_ms == -1; }
size_t size;
uint32_t first_timestamp;
uint32_t timestamp;
+ int64_t first_arrival_ms;
int64_t complete_time_ms;
int64_t last_system_time_ms;
};