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

Side by Side Diff: webrtc/modules/video_coding/codecs/h264/h264.cc

Issue 2474993002: Pass selected cricket::VideoCodec down to internal H264 encoder (Closed)
Patch Set: Fix includes. Created 4 years 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
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 26 matching lines...) Expand all
37 37
38 // If any H.264 codec is supported (iOS HW or OpenH264/FFmpeg). 38 // If any H.264 codec is supported (iOS HW or OpenH264/FFmpeg).
39 bool IsH264CodecSupported() { 39 bool IsH264CodecSupported() {
40 #if defined(WEBRTC_USE_H264) 40 #if defined(WEBRTC_USE_H264)
41 return g_rtc_use_h264; 41 return g_rtc_use_h264;
42 #else 42 #else
43 return false; 43 return false;
44 #endif 44 #endif
45 } 45 }
46 46
47 H264Encoder* H264Encoder::Create() { 47 H264Encoder* H264Encoder::Create(const cricket::VideoCodec& codec) {
48 RTC_DCHECK(H264Encoder::IsSupported()); 48 RTC_DCHECK(H264Encoder::IsSupported());
49 #if defined(WEBRTC_USE_H264) 49 #if defined(WEBRTC_USE_H264)
50 RTC_CHECK(g_rtc_use_h264); 50 RTC_CHECK(g_rtc_use_h264);
51 LOG(LS_INFO) << "Creating H264EncoderImpl."; 51 LOG(LS_INFO) << "Creating H264EncoderImpl.";
52 return new H264EncoderImpl(); 52 return new H264EncoderImpl();
53 #else 53 #else
54 RTC_NOTREACHED(); 54 RTC_NOTREACHED();
55 return nullptr; 55 return nullptr;
56 #endif 56 #endif
57 } 57 }
(...skipping 12 matching lines...) Expand all
70 RTC_NOTREACHED(); 70 RTC_NOTREACHED();
71 return nullptr; 71 return nullptr;
72 #endif 72 #endif
73 } 73 }
74 74
75 bool H264Decoder::IsSupported() { 75 bool H264Decoder::IsSupported() {
76 return IsH264CodecSupported(); 76 return IsH264CodecSupported();
77 } 77 }
78 78
79 } // namespace webrtc 79 } // namespace webrtc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698