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

Side by Side Diff: webrtc/video_encoder.h

Issue 2263043003: Make MediaCodecEncoder fallback to a software encoder on failure. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Return WEBRTC_VIDEO_CODEC_FALLBACK_SOFTWARE immediately. Created 4 years, 3 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
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2014 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2014 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 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
76 class VideoEncoder { 76 class VideoEncoder {
77 public: 77 public:
78 enum EncoderType { 78 enum EncoderType {
79 kH264, 79 kH264,
80 kVp8, 80 kVp8,
81 kVp9, 81 kVp9,
82 kUnsupportedCodec, 82 kUnsupportedCodec,
83 }; 83 };
84 84
85 static VideoEncoder* Create(EncoderType codec_type); 85 static VideoEncoder* Create(EncoderType codec_type);
86 // Returns true if this type of encoder can be created using
87 // VideoEncoder::Create.
88 static bool IsSupported(EncoderType codec_type);
86 89
87 static VideoCodecVP8 GetDefaultVp8Settings(); 90 static VideoCodecVP8 GetDefaultVp8Settings();
88 static VideoCodecVP9 GetDefaultVp9Settings(); 91 static VideoCodecVP9 GetDefaultVp9Settings();
89 static VideoCodecH264 GetDefaultH264Settings(); 92 static VideoCodecH264 GetDefaultH264Settings();
90 93
91 virtual ~VideoEncoder() {} 94 virtual ~VideoEncoder() {}
92 95
93 // Initialize the encoder with the information from the codecSettings 96 // Initialize the encoder with the information from the codecSettings
94 // 97 //
95 // Input: 98 // Input:
(...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after
212 215
213 const EncoderType encoder_type_; 216 const EncoderType encoder_type_;
214 webrtc::VideoEncoder* const encoder_; 217 webrtc::VideoEncoder* const encoder_;
215 218
216 std::unique_ptr<webrtc::VideoEncoder> fallback_encoder_; 219 std::unique_ptr<webrtc::VideoEncoder> fallback_encoder_;
217 std::string fallback_implementation_name_; 220 std::string fallback_implementation_name_;
218 EncodedImageCallback* callback_; 221 EncodedImageCallback* callback_;
219 }; 222 };
220 } // namespace webrtc 223 } // namespace webrtc
221 #endif // WEBRTC_VIDEO_ENCODER_H_ 224 #endif // WEBRTC_VIDEO_ENCODER_H_
OLDNEW
« webrtc/api/android/jni/androidmediaencoder_jni.cc ('K') | « webrtc/video/video_encoder.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698