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

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

Issue 2061423003: Refactor NACK bitrate allocation (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Fixed nit Created 4 years, 5 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 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 8307b83864de53302f9bf5cbe2973ad568c01073..7ce889b83c68c683e50e51957b5da6922ec11b24 100644
--- a/webrtc/modules/rtp_rtcp/source/rtp_sender_video.h
+++ b/webrtc/modules/rtp_rtcp/source/rtp_sender_video.h
@@ -15,10 +15,10 @@
#include "webrtc/base/criticalsection.h"
#include "webrtc/base/onetimeevent.h"
+#include "webrtc/base/rate_statistics.h"
#include "webrtc/base/thread_annotations.h"
#include "webrtc/common_types.h"
#include "webrtc/modules/rtp_rtcp/include/rtp_rtcp_defines.h"
-#include "webrtc/modules/rtp_rtcp/source/bitrate.h"
#include "webrtc/modules/rtp_rtcp/source/forward_error_correction.h"
#include "webrtc/modules/rtp_rtcp/source/producer_fec.h"
#include "webrtc/modules/rtp_rtcp/source/rtp_rtcp_config.h"
@@ -68,8 +68,6 @@ class RTPSenderVideo {
void SetFecParameters(const FecProtectionParams* delta_params,
const FecProtectionParams* key_params);
- void ProcessBitrate();
-
uint32_t VideoBitrateSent() const;
uint32_t FecOverheadRate() const;
@@ -95,9 +93,10 @@ class RTPSenderVideo {
bool protect);
RTPSenderInterface& _rtpSender;
+ Clock* const clock_;
// Should never be held when calling out of this class.
- const rtc::CriticalSection crit_;
+ rtc::CriticalSection crit_;
RtpVideoCodecTypes _videoType;
int32_t _retransmissionSettings GUARDED_BY(crit_);
@@ -111,11 +110,12 @@ class RTPSenderVideo {
FecProtectionParams key_fec_params_ GUARDED_BY(crit_);
ProducerFec producer_fec_ GUARDED_BY(crit_);
+ rtc::CriticalSection stats_crit_;
// Bitrate used for FEC payload, RED headers, RTP headers for FEC packets
// and any padding overhead.
- Bitrate _fecOverheadRate;
- // Bitrate used for video payload and RTP headers
- Bitrate _videoBitrate;
+ RateStatistics fec_bitrate_ GUARDED_BY(stats_crit_);
+ // Bitrate used for video payload and RTP headers.
+ RateStatistics video_bitrate_ GUARDED_BY(stats_crit_);
OneTimeEvent first_frame_sent_;
};
} // namespace webrtc
« no previous file with comments | « webrtc/modules/rtp_rtcp/source/rtp_sender_unittest.cc ('k') | webrtc/modules/rtp_rtcp/source/rtp_sender_video.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698