Refactor registerable callbacks for VideoBitrateObserver from rtp_rtcp module into vie_channel.

R=stefan@webrtc.org

Review URL: https://webrtc-codereview.appspot.com/20879004

git-svn-id: http://webrtc.googlecode.com/svn/trunk@6626 4adac7df-926f-26a2-2b94-8c16560cd09d
This commit is contained in:
andresp@webrtc.org
2014-07-08 14:32:58 +00:00
parent 3d7da88e06
commit d11bec40b2
8 changed files with 57 additions and 61 deletions

View File

@ -37,7 +37,8 @@ RtpRtcp::Configuration::Configuration()
rtt_stats(NULL),
audio_messages(NullObjectRtpAudioFeedback()),
remote_bitrate_estimator(NULL),
paced_sender(NULL) {
paced_sender(NULL),
send_bitrate_observer(NULL) {
}
RtpRtcp* RtpRtcp::CreateRtpRtcp(const RtpRtcp::Configuration& configuration) {
@ -60,7 +61,8 @@ ModuleRtpRtcpImpl::ModuleRtpRtcpImpl(const Configuration& configuration)
configuration.clock,
configuration.outgoing_transport,
configuration.audio_messages,
configuration.paced_sender),
configuration.paced_sender,
configuration.send_bitrate_observer),
rtcp_sender_(configuration.id,
configuration.audio,
configuration.clock,
@ -1234,16 +1236,6 @@ void ModuleRtpRtcpImpl::BitrateSent(uint32_t* total_rate,
*nack_rate = rtp_sender_.NackOverheadRate();
}
void ModuleRtpRtcpImpl::RegisterVideoBitrateObserver(
BitrateStatisticsObserver* observer) {
assert(!IsDefaultModule());
rtp_sender_.RegisterBitrateObserver(observer);
}
BitrateStatisticsObserver* ModuleRtpRtcpImpl::GetVideoBitrateObserver() const {
return rtp_sender_.GetBitrateObserver();
}
void ModuleRtpRtcpImpl::OnRequestIntraFrame() {
RequestKeyFrame();
}