Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(119)

Side by Side Diff: webrtc/modules/rtp_rtcp/source/flexfec_receiver.cc

Issue 2918333002: Reland of Only compare sequence numbers from the same SSRC in ForwardErrorCorrection. (Closed)
Patch Set: Let ForwardErrorCorrection be aware of its SSRCs. Created 3 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2016 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2016 The WebRTC project authors. All Rights Reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
(...skipping 16 matching lines...) Expand all
27 constexpr int kPacketLogIntervalMs = 10000; 27 constexpr int kPacketLogIntervalMs = 10000;
28 28
29 } // namespace 29 } // namespace
30 30
31 FlexfecReceiver::FlexfecReceiver( 31 FlexfecReceiver::FlexfecReceiver(
32 uint32_t ssrc, 32 uint32_t ssrc,
33 uint32_t protected_media_ssrc, 33 uint32_t protected_media_ssrc,
34 RecoveredPacketReceiver* recovered_packet_receiver) 34 RecoveredPacketReceiver* recovered_packet_receiver)
35 : ssrc_(ssrc), 35 : ssrc_(ssrc),
36 protected_media_ssrc_(protected_media_ssrc), 36 protected_media_ssrc_(protected_media_ssrc),
37 erasure_code_(ForwardErrorCorrection::CreateFlexfec()), 37 erasure_code_(
38 ForwardErrorCorrection::CreateFlexfec(ssrc, protected_media_ssrc)),
38 recovered_packet_receiver_(recovered_packet_receiver), 39 recovered_packet_receiver_(recovered_packet_receiver),
39 clock_(Clock::GetRealTimeClock()), 40 clock_(Clock::GetRealTimeClock()),
40 last_recovered_packet_ms_(-1) { 41 last_recovered_packet_ms_(-1) {
41 // It's OK to create this object on a different thread/task queue than 42 // It's OK to create this object on a different thread/task queue than
42 // the one used during main operation. 43 // the one used during main operation.
43 sequence_checker_.Detach(); 44 sequence_checker_.Detach();
44 } 45 }
45 46
46 FlexfecReceiver::~FlexfecReceiver() = default; 47 FlexfecReceiver::~FlexfecReceiver() = default;
47 48
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after
144 ForwardErrorCorrection::ParseSsrc(recovered_packet->pkt->data); 145 ForwardErrorCorrection::ParseSsrc(recovered_packet->pkt->data);
145 LOG(LS_VERBOSE) << "Recovered media packet with SSRC: " << media_ssrc 146 LOG(LS_VERBOSE) << "Recovered media packet with SSRC: " << media_ssrc
146 << " from FlexFEC stream with SSRC: " << ssrc_ << "."; 147 << " from FlexFEC stream with SSRC: " << ssrc_ << ".";
147 last_recovered_packet_ms_ = now_ms; 148 last_recovered_packet_ms_ = now_ms;
148 } 149 }
149 } 150 }
150 return true; 151 return true;
151 } 152 }
152 153
153 } // namespace webrtc 154 } // namespace webrtc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698