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

Unified Diff: webrtc/modules/rtp_rtcp/source/rtp_sender_video.h

Issue 2490523002: Wire up FlexfecSender in RTPSenderVideo. (Closed)
Patch Set: Created 4 years, 1 month 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 side-by-side diff with in-line comments
Download patch
Index: webrtc/modules/rtp_rtcp/source/rtp_sender_video.h
diff --git a/webrtc/modules/rtp_rtcp/source/rtp_sender_video.h b/webrtc/modules/rtp_rtcp/source/rtp_sender_video.h
index 56167eb6ebfc1ed7871c23e0dc017732054c653d..1a6bda33b3d4e1d6a49e8e1be2c9f3c5ce687cfe 100644
--- a/webrtc/modules/rtp_rtcp/source/rtp_sender_video.h
+++ b/webrtc/modules/rtp_rtcp/source/rtp_sender_video.h
@@ -13,6 +13,7 @@
#include <list>
#include <memory>
+#include <vector>
#include "webrtc/base/criticalsection.h"
#include "webrtc/base/onetimeevent.h"
@@ -20,8 +21,8 @@
#include "webrtc/base/sequenced_task_checker.h"
#include "webrtc/base/thread_annotations.h"
#include "webrtc/common_types.h"
+#include "webrtc/modules/rtp_rtcp/include/flexfec_sender.h"
#include "webrtc/modules/rtp_rtcp/include/rtp_rtcp_defines.h"
-#include "webrtc/modules/rtp_rtcp/source/forward_error_correction.h"
#include "webrtc/modules/rtp_rtcp/source/rtp_rtcp_config.h"
#include "webrtc/modules/rtp_rtcp/source/rtp_sender.h"
#include "webrtc/modules/rtp_rtcp/source/rtp_utility.h"
@@ -78,7 +79,7 @@ class RTPSenderVideo {
void SendVideoPacketAsRed(std::unique_ptr<RtpPacketToSend> media_packet,
StorageType media_packet_storage,
- bool protect);
+ bool protect_packet);
bool red_enabled() const EXCLUSIVE_LOCKS_REQUIRED(crit_) {
return red_payload_type_ >= 0;
@@ -88,6 +89,14 @@ class RTPSenderVideo {
return ulpfec_payload_type_ >= 0;
}
+ // TODO(brandtr): Remove these when FlexfecSender has been moved to
+ // PacedSender.
+ bool flexfec_enabled() const { return flexfec_sender_ != nullptr; }
+ std::vector<std::unique_ptr<RtpPacketToSend>> GetFlexfecPackets(
danilchap 2016/11/08 11:45:08 this function do more than get fec packets. May be
brandtr 2016/11/09 10:40:00 I merged it into one function, because then the co
+ const RtpPacketToSend& media_packet);
+ void SendFlexfecPackets(
+ std::vector<std::unique_ptr<RtpPacketToSend>>* fec_packets);
+
RTPSender* const rtp_sender_;
Clock* const clock_;
@@ -102,9 +111,14 @@ class RTPSenderVideo {
// RED/ULPFEC.
int red_payload_type_ GUARDED_BY(crit_);
int ulpfec_payload_type_ GUARDED_BY(crit_);
+ UlpfecGenerator ulpfec_generator_ GUARDED_BY(crit_);
+
+ // FlexFEC.
+ FlexfecSender* const flexfec_sender_;
+
+ // FEC parameters, applicable to either ULPFEC or FlexFEC.
FecProtectionParams delta_fec_params_ GUARDED_BY(crit_);
FecProtectionParams key_fec_params_ GUARDED_BY(crit_);
- UlpfecGenerator ulpfec_generator_ GUARDED_BY(crit_);
rtc::CriticalSection stats_crit_;
// Bitrate used for FEC payload, RED headers, RTP headers for FEC packets
« no previous file with comments | « no previous file | webrtc/modules/rtp_rtcp/source/rtp_sender_video.cc » ('j') | webrtc/modules/rtp_rtcp/source/rtp_sender_video.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698