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

Side by Side Diff: webrtc/call/rtc_event_log.cc

Issue 1373903003: Unify newapi::RtcpMode and RTCPMethod. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: ehm, compile the code Created 5 years, 2 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 unified diff | Download patch
« no previous file with comments | « talk/media/webrtc/webrtcvideoengine2_unittest.cc ('k') | webrtc/call/rtc_event_log_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2015 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2015 The WebRTC project authors. All Rights Reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after
104 104
105 namespace { 105 namespace {
106 // The functions in this namespace convert enums from the runtime format 106 // The functions in this namespace convert enums from the runtime format
107 // that the rest of the WebRtc project can use, to the corresponding 107 // that the rest of the WebRtc project can use, to the corresponding
108 // serialized enum which is defined by the protobuf. 108 // serialized enum which is defined by the protobuf.
109 109
110 // Do not add default return values to the conversion functions in this 110 // Do not add default return values to the conversion functions in this
111 // unnamed namespace. The intention is to make the compiler warn if anyone 111 // unnamed namespace. The intention is to make the compiler warn if anyone
112 // adds unhandled new events/modes/etc. 112 // adds unhandled new events/modes/etc.
113 113
114 rtclog::VideoReceiveConfig_RtcpMode ConvertRtcpMode( 114 rtclog::VideoReceiveConfig_RtcpMode ConvertRtcpMode(RtcpMode rtcp_mode) {
115 newapi::RtcpMode rtcp_mode) {
116 switch (rtcp_mode) { 115 switch (rtcp_mode) {
117 case newapi::kRtcpCompound: 116 case RtcpMode::kCompound:
118 return rtclog::VideoReceiveConfig::RTCP_COMPOUND; 117 return rtclog::VideoReceiveConfig::RTCP_COMPOUND;
119 case newapi::kRtcpReducedSize: 118 case RtcpMode::kReducedSize:
120 return rtclog::VideoReceiveConfig::RTCP_REDUCEDSIZE; 119 return rtclog::VideoReceiveConfig::RTCP_REDUCEDSIZE;
120 case RtcpMode::kOff:
121 RTC_NOTREACHED();
122 return rtclog::VideoReceiveConfig::RTCP_COMPOUND;
121 } 123 }
122 RTC_NOTREACHED(); 124 RTC_NOTREACHED();
123 return rtclog::VideoReceiveConfig::RTCP_COMPOUND; 125 return rtclog::VideoReceiveConfig::RTCP_COMPOUND;
124 } 126 }
125 127
126 rtclog::MediaType ConvertMediaType(MediaType media_type) { 128 rtclog::MediaType ConvertMediaType(MediaType media_type) {
127 switch (media_type) { 129 switch (media_type) {
128 case MediaType::ANY: 130 case MediaType::ANY:
129 return rtclog::MediaType::ANY; 131 return rtclog::MediaType::ANY;
130 case MediaType::AUDIO: 132 case MediaType::AUDIO:
(...skipping 265 matching lines...) Expand 10 before | Expand all | Expand 10 after
396 return result->ParseFromString(dump_buffer); 398 return result->ParseFromString(dump_buffer);
397 } 399 }
398 400
399 #endif // ENABLE_RTC_EVENT_LOG 401 #endif // ENABLE_RTC_EVENT_LOG
400 402
401 // RtcEventLog member functions. 403 // RtcEventLog member functions.
402 rtc::scoped_ptr<RtcEventLog> RtcEventLog::Create() { 404 rtc::scoped_ptr<RtcEventLog> RtcEventLog::Create() {
403 return rtc::scoped_ptr<RtcEventLog>(new RtcEventLogImpl()); 405 return rtc::scoped_ptr<RtcEventLog>(new RtcEventLogImpl());
404 } 406 }
405 } // namespace webrtc 407 } // namespace webrtc
OLDNEW
« no previous file with comments | « talk/media/webrtc/webrtcvideoengine2_unittest.cc ('k') | webrtc/call/rtc_event_log_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698