Add RTP timestamp to contributing sources
RTP timestamp was recently added to contributing sources in the WebRTC specification. This CL implements that change in WebRTC. Bug: webrtc:10650 Change-Id: Ic0ccfbea7049a5b66063fa6cf60d01d5bd713132 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/137515 Reviewed-by: Fredrik Solenberg <solenberg@webrtc.org> Reviewed-by: Ilya Nikolaevskiy <ilnik@webrtc.org> Reviewed-by: Danil Chapovalov <danilchap@webrtc.org> Commit-Queue: Johannes Kron <kron@webrtc.org> Cr-Commit-Position: refs/heads/master@{#28020}
This commit is contained in:
committed by
Commit Bot
parent
afb8d5cdae
commit
b5d918324c
@ -32,8 +32,10 @@ class ContributingSources {
|
||||
ContributingSources();
|
||||
~ContributingSources();
|
||||
|
||||
void Update(int64_t now_ms, rtc::ArrayView<const uint32_t> csrcs,
|
||||
absl::optional<uint8_t> audio_level);
|
||||
void Update(int64_t now_ms,
|
||||
rtc::ArrayView<const uint32_t> csrcs,
|
||||
absl::optional<uint8_t> audio_level,
|
||||
uint32_t rtp_timestamp);
|
||||
|
||||
// Returns contributing sources seen the last 10 s.
|
||||
std::vector<RtpSource> GetSources(int64_t now_ms) const;
|
||||
@ -41,10 +43,13 @@ class ContributingSources {
|
||||
private:
|
||||
struct Entry {
|
||||
Entry();
|
||||
Entry(int64_t timestamp_ms, absl::optional<uint8_t> audio_level);
|
||||
Entry(int64_t timestamp_ms,
|
||||
absl::optional<uint8_t> audio_level,
|
||||
uint32_t rtp_timestamp);
|
||||
|
||||
int64_t last_seen_ms;
|
||||
absl::optional<uint8_t> audio_level;
|
||||
uint32_t rtp_timestamp;
|
||||
};
|
||||
|
||||
void DeleteOldEntries(int64_t now_ms);
|
||||
|
||||
Reference in New Issue
Block a user