diff options
author | wu@webrtc.org <wu@webrtc.org@4adac7df-926f-26a2-2b94-8c16560cd09d> | 2013-08-15 23:38:54 +0000 |
---|---|---|
committer | wu@webrtc.org <wu@webrtc.org@4adac7df-926f-26a2-2b94-8c16560cd09d> | 2013-08-15 23:38:54 +0000 |
commit | 7fc75bbb65cc1cd99fdf45d9fce44bcce1396dfa (patch) | |
tree | 604dea40012e66f2a2b22d3637de4ee97d0cb325 /video_engine/vie_network_impl.cc | |
parent | 1e817c3d470262a8dc0d7f151feb0519a65e0d26 (diff) | |
download | webrtc-7fc75bbb65cc1cd99fdf45d9fce44bcce1396dfa.tar.gz |
Update talk to 50918584.
Together with Stefan's http://review.webrtc.org/1960004/.
R=mallinath@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/2048004
git-svn-id: http://webrtc.googlecode.com/svn/trunk/webrtc@4556 4adac7df-926f-26a2-2b94-8c16560cd09d
Diffstat (limited to 'video_engine/vie_network_impl.cc')
-rw-r--r-- | video_engine/vie_network_impl.cc | 95 |
1 files changed, 0 insertions, 95 deletions
diff --git a/video_engine/vie_network_impl.cc b/video_engine/vie_network_impl.cc index e9082daa..0afd2fe8 100644 --- a/video_engine/vie_network_impl.cc +++ b/video_engine/vie_network_impl.cc @@ -196,99 +196,4 @@ int ViENetworkImpl::SetMTU(int video_channel, unsigned int mtu) { } return 0; } - -int ViENetworkImpl::SetPacketTimeoutNotification(const int video_channel, - bool enable, - int timeout_seconds) { - WEBRTC_TRACE(kTraceApiCall, kTraceVideo, - ViEId(shared_data_->instance_id(), video_channel), - "%s(channel: %d, enable: %d, timeout_seconds: %u)", - __FUNCTION__, video_channel, enable, timeout_seconds); - ViEChannelManagerScoped cs(*(shared_data_->channel_manager())); - ViEChannel* vie_channel = cs.Channel(video_channel); - if (!vie_channel) { - WEBRTC_TRACE(kTraceError, kTraceVideo, - ViEId(shared_data_->instance_id(), video_channel), - "Channel doesn't exist"); - shared_data_->SetLastError(kViENetworkInvalidChannelId); - return -1; - } - if (vie_channel->SetPacketTimeoutNotification(enable, - timeout_seconds) != 0) { - shared_data_->SetLastError(kViENetworkUnknownError); - return -1; - } - return 0; -} - -int ViENetworkImpl::RegisterObserver(const int video_channel, - ViENetworkObserver& observer) { - WEBRTC_TRACE(kTraceApiCall, kTraceVideo, - ViEId(shared_data_->instance_id(), video_channel), - "%s(channel: %d)", __FUNCTION__, video_channel); - ViEChannelManagerScoped cs(*(shared_data_->channel_manager())); - ViEChannel* vie_channel = cs.Channel(video_channel); - if (!vie_channel) { - WEBRTC_TRACE(kTraceError, kTraceVideo, - ViEId(shared_data_->instance_id(), video_channel), - "Channel doesn't exist"); - shared_data_->SetLastError(kViENetworkInvalidChannelId); - return -1; - } - if (vie_channel->RegisterNetworkObserver(&observer) != 0) { - shared_data_->SetLastError(kViENetworkObserverAlreadyRegistered); - return -1; - } - return 0; -} - -int ViENetworkImpl::DeregisterObserver(const int video_channel) { - WEBRTC_TRACE(kTraceApiCall, kTraceVideo, - ViEId(shared_data_->instance_id(), video_channel), - "%s(channel: %d)", __FUNCTION__, video_channel); - ViEChannelManagerScoped cs(*(shared_data_->channel_manager())); - ViEChannel* vie_channel = cs.Channel(video_channel); - if (!vie_channel) { - WEBRTC_TRACE(kTraceError, kTraceVideo, - ViEId(shared_data_->instance_id(), video_channel), - "Channel doesn't exist"); - shared_data_->SetLastError(kViENetworkInvalidChannelId); - return -1; - } - if (!vie_channel->NetworkObserverRegistered()) { - shared_data_->SetLastError(kViENetworkObserverNotRegistered); - return -1; - } - return vie_channel->RegisterNetworkObserver(NULL); -} - -int ViENetworkImpl::SetPeriodicDeadOrAliveStatus( - const int video_channel, - bool enable, - unsigned int sample_time_seconds) { - WEBRTC_TRACE(kTraceApiCall, kTraceVideo, - ViEId(shared_data_->instance_id(), video_channel), - "%s(channel: %d, enable: %d, sample_time_seconds: %ul)", - __FUNCTION__, video_channel, enable, sample_time_seconds); - ViEChannelManagerScoped cs(*(shared_data_->channel_manager())); - ViEChannel* vie_channel = cs.Channel(video_channel); - if (!vie_channel) { - WEBRTC_TRACE(kTraceError, kTraceVideo, - ViEId(shared_data_->instance_id(), video_channel), - "Channel doesn't exist"); - shared_data_->SetLastError(kViENetworkInvalidChannelId); - return -1; - } - if (!vie_channel->NetworkObserverRegistered()) { - shared_data_->SetLastError(kViENetworkObserverNotRegistered); - return -1; - } - if (vie_channel->SetPeriodicDeadOrAliveStatus(enable, sample_time_seconds) - != 0) { - shared_data_->SetLastError(kViENetworkUnknownError); - return -1; - } - return 0; -} - } // namespace webrtc |