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 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
48 int32_t SetTransportCallback(VCMPacketizationCallback* transport); | 48 int32_t SetTransportCallback(VCMPacketizationCallback* transport); |
49 /** | 49 /** |
50 * Set media Optimization | 50 * Set media Optimization |
51 */ | 51 */ |
52 void SetMediaOpt (media_optimization::MediaOptimization* mediaOpt); | 52 void SetMediaOpt (media_optimization::MediaOptimization* mediaOpt); |
53 | 53 |
54 void SetPayloadType(uint8_t payloadType) { _payloadType = payloadType; }; | 54 void SetPayloadType(uint8_t payloadType) { _payloadType = payloadType; }; |
55 void SetInternalSource(bool internalSource) { _internalSource = internalSour
ce; }; | 55 void SetInternalSource(bool internalSource) { _internalSource = internalSour
ce; }; |
56 | 56 |
57 void SetRotation(VideoRotation rotation) { _rotation = rotation; } | 57 void SetRotation(VideoRotation rotation) { _rotation = rotation; } |
| 58 void LastEncoderImplementationUsed(const char* encoder_implementation_name); |
58 | 59 |
59 private: | 60 private: |
60 VCMPacketizationCallback* _sendCallback; | 61 VCMPacketizationCallback* send_callback_; |
61 media_optimization::MediaOptimization* _mediaOpt; | 62 media_optimization::MediaOptimization* _mediaOpt; |
62 uint8_t _payloadType; | 63 uint8_t _payloadType; |
63 bool _internalSource; | 64 bool _internalSource; |
64 VideoRotation _rotation; | 65 VideoRotation _rotation; |
65 | 66 |
66 EncodedImageCallback* post_encode_callback_; | 67 EncodedImageCallback* post_encode_callback_; |
67 | 68 |
68 #ifdef DEBUG_ENCODER_BIT_STREAM | 69 #ifdef DEBUG_ENCODER_BIT_STREAM |
69 FILE* _bitStreamAfterEncoder; | 70 FILE* _bitStreamAfterEncoder; |
70 #endif | 71 #endif |
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
138 | 139 |
139 void OnDroppedFrame(); | 140 void OnDroppedFrame(); |
140 | 141 |
141 bool SupportsNativeHandle() const; | 142 bool SupportsNativeHandle() const; |
142 | 143 |
143 int GetTargetFramerate(); | 144 int GetTargetFramerate(); |
144 | 145 |
145 private: | 146 private: |
146 VideoEncoder* const encoder_; | 147 VideoEncoder* const encoder_; |
147 VideoEncoderRateObserver* const rate_observer_; | 148 VideoEncoderRateObserver* const rate_observer_; |
148 VCMEncodedFrameCallback* vcm_encoded_frame_callback_; | 149 VCMEncodedFrameCallback* vcm_encoded_frame_callback_; |
149 uint32_t bit_rate_; | 150 mutable rtc::CriticalSection rates_lock_; |
150 uint32_t frame_rate_; | 151 uint32_t bit_rate_ GUARDED_BY(rates_lock_); |
| 152 uint32_t frame_rate_ GUARDED_BY(rates_lock_); |
151 const bool internal_source_; | 153 const bool internal_source_; |
152 mutable rtc::CriticalSection rates_lock_; | |
153 VideoRotation rotation_; | 154 VideoRotation rotation_; |
154 bool is_screenshare_; | 155 bool is_screenshare_; |
155 }; // end of VCMGenericEncoder class | 156 }; // end of VCMGenericEncoder class |
156 | 157 |
157 } // namespace webrtc | 158 } // namespace webrtc |
158 | 159 |
159 #endif // WEBRTC_MODULES_VIDEO_CODING_GENERIC_ENCODER_H_ | 160 #endif // WEBRTC_MODULES_VIDEO_CODING_GENERIC_ENCODER_H_ |
OLD | NEW |