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

Side by Side Diff: webrtc/media/engine/webrtcvideoencoderfactory.h

Issue 3007073002: Add new video codec factories (Closed)
Patch Set: . Created 3 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) 2013 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2013 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
11 #ifndef WEBRTC_MEDIA_ENGINE_WEBRTCVIDEOENCODERFACTORY_H_ 11 #ifndef WEBRTC_MEDIA_ENGINE_WEBRTCVIDEOENCODERFACTORY_H_
12 #define WEBRTC_MEDIA_ENGINE_WEBRTCVIDEOENCODERFACTORY_H_ 12 #define WEBRTC_MEDIA_ENGINE_WEBRTCVIDEOENCODERFACTORY_H_
13 13
14 #include <vector> 14 #include <vector>
15 15
16 #include "webrtc/common_types.h" 16 #include "webrtc/common_types.h"
17 #include "webrtc/media/base/codec.h" 17 #include "webrtc/media/base/codec.h"
18 18
19 namespace webrtc { 19 namespace webrtc {
20 class VideoEncoder; 20 class VideoEncoder;
21 } 21 }
22 22
23 namespace cricket { 23 namespace cricket {
24 24
25 // Deprecated. Use webrtc::VideoEncoderFactory instead.
26 // https://bugs.chromium.org/p/webrtc/issues/detail?id=7925
25 class WebRtcVideoEncoderFactory { 27 class WebRtcVideoEncoderFactory {
26 public: 28 public:
27 virtual ~WebRtcVideoEncoderFactory() {} 29 virtual ~WebRtcVideoEncoderFactory() {}
28 30
29 // Caller takes the ownership of the returned object and it should be released 31 // Caller takes the ownership of the returned object and it should be released
30 // by calling DestroyVideoEncoder(). 32 // by calling DestroyVideoEncoder().
31 virtual webrtc::VideoEncoder* CreateVideoEncoder( 33 virtual webrtc::VideoEncoder* CreateVideoEncoder(
32 const cricket::VideoCodec& codec) = 0; 34 const cricket::VideoCodec& codec) = 0;
33 35
34 // Returns a list of supported codecs in order of preference. 36 // Returns a list of supported codecs in order of preference.
35 virtual const std::vector<cricket::VideoCodec>& supported_codecs() const = 0; 37 virtual const std::vector<cricket::VideoCodec>& supported_codecs() const = 0;
36 38
37 // Returns true if encoders created by this factory of the given codec type 39 // Returns true if encoders created by this factory of the given codec type
38 // will use internal camera sources, meaning that they don't require/expect 40 // will use internal camera sources, meaning that they don't require/expect
39 // frames to be delivered via webrtc::VideoEncoder::Encode. This flag is used 41 // frames to be delivered via webrtc::VideoEncoder::Encode.
40 // as the internal_source parameter to
41 // webrtc::ViEExternalCodec::RegisterExternalSendCodec.
42 virtual bool EncoderTypeHasInternalSource(webrtc::VideoCodecType type) const { 42 virtual bool EncoderTypeHasInternalSource(webrtc::VideoCodecType type) const {
43 return false; 43 return false;
44 } 44 }
45 45
46 virtual void DestroyVideoEncoder(webrtc::VideoEncoder* encoder) = 0; 46 virtual void DestroyVideoEncoder(webrtc::VideoEncoder* encoder) = 0;
47 }; 47 };
48 48
49 } // namespace cricket 49 } // namespace cricket
50 50
51 #endif // WEBRTC_MEDIA_ENGINE_WEBRTCVIDEOENCODERFACTORY_H_ 51 #endif // WEBRTC_MEDIA_ENGINE_WEBRTCVIDEOENCODERFACTORY_H_
OLDNEW
« no previous file with comments | « webrtc/media/engine/webrtcvideodecoderfactory.h ('k') | webrtc/media/engine/webrtcvideoengine.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698