OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2012 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 Loading... |
37 public: | 37 public: |
38 explicit VCMEncodedFrameCallback(EncodedImageCallback* post_encode_callback); | 38 explicit VCMEncodedFrameCallback(EncodedImageCallback* post_encode_callback); |
39 virtual ~VCMEncodedFrameCallback(); | 39 virtual ~VCMEncodedFrameCallback(); |
40 | 40 |
41 // Implements EncodedImageCallback. | 41 // Implements EncodedImageCallback. |
42 int32_t Encoded(const EncodedImage& encoded_image, | 42 int32_t Encoded(const EncodedImage& encoded_image, |
43 const CodecSpecificInfo* codec_specific, | 43 const CodecSpecificInfo* codec_specific, |
44 const RTPFragmentationHeader* fragmentation_header) override; | 44 const RTPFragmentationHeader* fragmentation_header) override; |
45 int32_t SetTransportCallback(VCMPacketizationCallback* transport); | 45 int32_t SetTransportCallback(VCMPacketizationCallback* transport); |
46 void SetMediaOpt(media_optimization::MediaOptimization* media_opt); | 46 void SetMediaOpt(media_optimization::MediaOptimization* media_opt); |
47 void SetPayloadType(uint8_t payload_type) { payload_type_ = payload_type; } | |
48 void SetInternalSource(bool internal_source) { | 47 void SetInternalSource(bool internal_source) { |
49 internal_source_ = internal_source; | 48 internal_source_ = internal_source; |
50 } | 49 } |
51 void SignalLastEncoderImplementationUsed( | 50 void SignalLastEncoderImplementationUsed( |
52 const char* encoder_implementation_name); | 51 const char* encoder_implementation_name); |
53 | 52 |
54 private: | 53 private: |
55 VCMPacketizationCallback* send_callback_; | 54 VCMPacketizationCallback* send_callback_; |
56 media_optimization::MediaOptimization* media_opt_; | 55 media_optimization::MediaOptimization* media_opt_; |
57 uint8_t payload_type_; | |
58 bool internal_source_; | 56 bool internal_source_; |
59 | 57 |
60 EncodedImageCallback* post_encode_callback_; | 58 EncodedImageCallback* post_encode_callback_; |
61 }; | 59 }; |
62 | 60 |
63 class VCMGenericEncoder { | 61 class VCMGenericEncoder { |
64 friend class VCMCodecDataBase; | 62 friend class VCMCodecDataBase; |
65 | 63 |
66 public: | 64 public: |
67 VCMGenericEncoder(VideoEncoder* encoder, | 65 VCMGenericEncoder(VideoEncoder* encoder, |
(...skipping 25 matching lines...) Expand all Loading... |
93 VCMEncodedFrameCallback* const vcm_encoded_frame_callback_; | 91 VCMEncodedFrameCallback* const vcm_encoded_frame_callback_; |
94 const bool internal_source_; | 92 const bool internal_source_; |
95 rtc::CriticalSection params_lock_; | 93 rtc::CriticalSection params_lock_; |
96 EncoderParameters encoder_params_ GUARDED_BY(params_lock_); | 94 EncoderParameters encoder_params_ GUARDED_BY(params_lock_); |
97 bool is_screenshare_; | 95 bool is_screenshare_; |
98 }; | 96 }; |
99 | 97 |
100 } // namespace webrtc | 98 } // namespace webrtc |
101 | 99 |
102 #endif // WEBRTC_MODULES_VIDEO_CODING_GENERIC_ENCODER_H_ | 100 #endif // WEBRTC_MODULES_VIDEO_CODING_GENERIC_ENCODER_H_ |
OLD | NEW |