| OLD | NEW |
| 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 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 42 int Release() override; | 42 int Release() override; |
| 43 int InitEncode(const VideoCodec* inst, | 43 int InitEncode(const VideoCodec* inst, |
| 44 int number_of_cores, | 44 int number_of_cores, |
| 45 size_t max_payload_size) override; | 45 size_t max_payload_size) override; |
| 46 int Encode(const VideoFrame& input_image, | 46 int Encode(const VideoFrame& input_image, |
| 47 const CodecSpecificInfo* codec_specific_info, | 47 const CodecSpecificInfo* codec_specific_info, |
| 48 const std::vector<FrameType>* frame_types) override; | 48 const std::vector<FrameType>* frame_types) override; |
| 49 int RegisterEncodeCompleteCallback(EncodedImageCallback* callback) override; | 49 int RegisterEncodeCompleteCallback(EncodedImageCallback* callback) override; |
| 50 int SetChannelParameters(uint32_t packet_loss, int64_t rtt) override; | 50 int SetChannelParameters(uint32_t packet_loss, int64_t rtt) override; |
| 51 int SetRates(uint32_t new_bitrate_kbit, uint32_t new_framerate) override; | 51 int SetRates(uint32_t new_bitrate_kbit, uint32_t new_framerate) override; |
| 52 int SetRateAllocation(const BitrateAllocation& bitrate, |
| 53 uint32_t new_framerate) override; |
| 52 | 54 |
| 53 // Eventual handler for the contained encoders' EncodedImageCallbacks, but | 55 // Eventual handler for the contained encoders' EncodedImageCallbacks, but |
| 54 // called from an internal helper that also knows the correct stream | 56 // called from an internal helper that also knows the correct stream |
| 55 // index. | 57 // index. |
| 56 EncodedImageCallback::Result OnEncodedImage( | 58 EncodedImageCallback::Result OnEncodedImage( |
| 57 size_t stream_idx, | 59 size_t stream_idx, |
| 58 const EncodedImage& encoded_image, | 60 const EncodedImage& encoded_image, |
| 59 const CodecSpecificInfo* codec_specific_info, | 61 const CodecSpecificInfo* codec_specific_info, |
| 60 const RTPFragmentationHeader* fragmentation); | 62 const RTPFragmentationHeader* fragmentation); |
| 61 | 63 |
| (...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 96 // Populate the codec settings for each stream. | 98 // Populate the codec settings for each stream. |
| 97 void PopulateStreamCodec(const webrtc::VideoCodec* inst, | 99 void PopulateStreamCodec(const webrtc::VideoCodec* inst, |
| 98 int stream_index, | 100 int stream_index, |
| 99 uint32_t start_bitrate_kbps, | 101 uint32_t start_bitrate_kbps, |
| 100 bool highest_resolution_stream, | 102 bool highest_resolution_stream, |
| 101 webrtc::VideoCodec* stream_codec); | 103 webrtc::VideoCodec* stream_codec); |
| 102 | 104 |
| 103 bool Initialized() const; | 105 bool Initialized() const; |
| 104 | 106 |
| 105 std::unique_ptr<VideoEncoderFactory> factory_; | 107 std::unique_ptr<VideoEncoderFactory> factory_; |
| 106 std::unique_ptr<TemporalLayersFactory> screensharing_tl_factory_; | |
| 107 VideoCodec codec_; | 108 VideoCodec codec_; |
| 108 std::vector<StreamInfo> streaminfos_; | 109 std::vector<StreamInfo> streaminfos_; |
| 109 EncodedImageCallback* encoded_complete_callback_; | 110 EncodedImageCallback* encoded_complete_callback_; |
| 110 std::string implementation_name_; | 111 std::string implementation_name_; |
| 111 std::unique_ptr<SimulcastRateAllocator> rate_allocator_; | 112 std::unique_ptr<SimulcastRateAllocator> fallback_rate_allocator_; |
| 112 }; | 113 }; |
| 113 | 114 |
| 114 } // namespace webrtc | 115 } // namespace webrtc |
| 115 | 116 |
| 116 #endif // WEBRTC_MODULES_VIDEO_CODING_CODECS_VP8_SIMULCAST_ENCODER_ADAPTER_H_ | 117 #endif // WEBRTC_MODULES_VIDEO_CODING_CODECS_VP8_SIMULCAST_ENCODER_ADAPTER_H_ |
| OLD | NEW |