Add interface to signal a network down event.
- In real-time mode encoding will be paused until the network is back up. - In buffering mode the encoder will keep encoding, and packets will be buffered at the sender. When the buffer grows above the target delay encoding will be paused. - Fixes a couple of issues related to pacing which was found with the new test. - Introduces different max bitrates for pacing and for encoding. This allows the pacer to faster get rid of the queue after a network down event. (Work based on issue 1237004) BUG=1524 TESTS=trybots,vie_auto_test Review URL: https://webrtc-codereview.appspot.com/1258004 git-svn-id: http://webrtc.googlecode.com/svn/trunk@3730 4adac7df-926f-26a2-2b94-8c16560cd09d
This commit is contained in:
@@ -987,15 +987,25 @@ void ModuleRtpRtcpImpl::TimeToSendPacket(uint32_t ssrc,
|
||||
(*it)->rtp_sender_.TimeToSendPacket(sequence_number, capture_time_ms);
|
||||
return;
|
||||
}
|
||||
it++;
|
||||
++it;
|
||||
}
|
||||
} else {
|
||||
bool have_child_modules(child_modules_.empty() ? false : true);
|
||||
bool have_child_modules = !child_modules_.empty();
|
||||
if (!have_child_modules) {
|
||||
// Don't send from default module.
|
||||
if (SendingMedia() && ssrc == rtp_sender_.SSRC()) {
|
||||
rtp_sender_.TimeToSendPacket(sequence_number, capture_time_ms);
|
||||
}
|
||||
} else {
|
||||
CriticalSectionScoped lock(critical_section_module_ptrs_.get());
|
||||
std::list<ModuleRtpRtcpImpl*>::iterator it = child_modules_.begin();
|
||||
while (it != child_modules_.end()) {
|
||||
if ((*it)->SendingMedia() && ssrc == (*it)->rtp_sender_.SSRC()) {
|
||||
(*it)->rtp_sender_.TimeToSendPacket(sequence_number, capture_time_ms);
|
||||
return;
|
||||
}
|
||||
++it;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user