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

Unified Diff: webrtc/modules/video_coding/video_receiver.cc

Issue 1778503002: Experiment for the nack module. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Added histogram to BUILD.gn. Created 4 years, 9 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
« no previous file with comments | « webrtc/modules/video_coding/video_coding_impl.cc ('k') | webrtc/video/video_receive_stream.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/modules/video_coding/video_receiver.cc
diff --git a/webrtc/modules/video_coding/video_receiver.cc b/webrtc/modules/video_coding/video_receiver.cc
index e7844d0add3aaf2c2f441043278f0264c27c6f76..5aadcf91e0eb41a1f3ed8b244db7c0de9d186f77 100644
--- a/webrtc/modules/video_coding/video_receiver.cc
+++ b/webrtc/modules/video_coding/video_receiver.cc
@@ -25,12 +25,19 @@
namespace webrtc {
namespace vcm {
-VideoReceiver::VideoReceiver(Clock* clock, EventFactory* event_factory)
+VideoReceiver::VideoReceiver(Clock* clock,
+ EventFactory* event_factory,
+ NackSender* nack_sender,
+ KeyFrameRequestSender* keyframe_request_sender)
: clock_(clock),
process_crit_sect_(CriticalSectionWrapper::CreateCriticalSection()),
_receiveCritSect(CriticalSectionWrapper::CreateCriticalSection()),
_timing(clock_),
- _receiver(&_timing, clock_, event_factory),
+ _receiver(&_timing,
+ clock_,
+ event_factory,
+ nack_sender,
+ keyframe_request_sender),
_decodedFrameCallback(&_timing, clock_),
_frameTypeCallback(NULL),
_receiveStatsCallback(NULL),
@@ -110,6 +117,10 @@ void VideoReceiver::Process() {
RequestKeyFrame();
}
+ if (_receiver.TimeUntilNextProcess() == 0) {
+ _receiver.Process();
+ }
+
// Packet retransmission requests
// TODO(holmer): Add API for changing Process interval and make sure it's
// disabled when NACK is off.
@@ -150,6 +161,8 @@ int64_t VideoReceiver::TimeUntilNextProcess() {
}
timeUntilNextProcess =
VCM_MIN(timeUntilNextProcess, _keyRequestTimer.TimeUntilProcess());
+ timeUntilNextProcess =
+ VCM_MIN(timeUntilNextProcess, _receiver.TimeUntilNextProcess());
return timeUntilNextProcess;
}
« no previous file with comments | « webrtc/modules/video_coding/video_coding_impl.cc ('k') | webrtc/video/video_receive_stream.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698