OLD | NEW |
1 /* Copyright (c) 2011 The WebRTC project authors. All Rights Reserved. | 1 /* Copyright (c) 2011 The WebRTC project authors. All Rights Reserved. |
2 * | 2 * |
3 * Use of this source code is governed by a BSD-style license | 3 * Use of this source code is governed by a BSD-style license |
4 * that can be found in the LICENSE file in the root of the source | 4 * that can be found in the LICENSE file in the root of the source |
5 * tree. An additional intellectual property rights grant can be found | 5 * tree. An additional intellectual property rights grant can be found |
6 * in the file PATENTS. All contributing project authors may | 6 * in the file PATENTS. All contributing project authors may |
7 * be found in the AUTHORS file in the root of the source tree. | 7 * be found in the AUTHORS file in the root of the source tree. |
8 */ | 8 */ |
9 /* | 9 /* |
10 * This file defines the interface for doing temporal layers with VP8. | 10 * This file defines the interface for doing temporal layers with VP8. |
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
81 // Returns true iff the configuration was actually modified. | 81 // Returns true iff the configuration was actually modified. |
82 virtual bool UpdateConfiguration(vpx_codec_enc_cfg_t* cfg) = 0; | 82 virtual bool UpdateConfiguration(vpx_codec_enc_cfg_t* cfg) = 0; |
83 | 83 |
84 virtual void PopulateCodecSpecific(bool is_keyframe, | 84 virtual void PopulateCodecSpecific(bool is_keyframe, |
85 CodecSpecificInfoVP8* vp8_info, | 85 CodecSpecificInfoVP8* vp8_info, |
86 uint32_t timestamp) = 0; | 86 uint32_t timestamp) = 0; |
87 | 87 |
88 virtual void FrameEncoded(unsigned int size, int qp) = 0; | 88 virtual void FrameEncoded(unsigned int size, int qp) = 0; |
89 | 89 |
90 virtual int CurrentLayerId() const = 0; | 90 virtual int CurrentLayerId() const = 0; |
| 91 |
| 92 // Returns the current tl0_pic_idx, so it can be reused in future |
| 93 // instantiations. |
| 94 virtual uint8_t Tl0PicIdx() const = 0; |
91 }; | 95 }; |
92 | 96 |
93 class TemporalLayersListener; | 97 class TemporalLayersListener; |
94 class TemporalLayersFactory { | 98 class TemporalLayersFactory { |
95 public: | 99 public: |
96 TemporalLayersFactory() : listener_(nullptr) {} | 100 TemporalLayersFactory() : listener_(nullptr) {} |
97 virtual ~TemporalLayersFactory() {} | 101 virtual ~TemporalLayersFactory() {} |
98 virtual TemporalLayers* Create(int simulcast_id, | 102 virtual TemporalLayers* Create(int simulcast_id, |
99 int temporal_layers, | 103 int temporal_layers, |
100 uint8_t initial_tl0_pic_idx) const; | 104 uint8_t initial_tl0_pic_idx) const; |
(...skipping 17 matching lines...) Expand all Loading... |
118 public: | 122 public: |
119 TemporalLayersListener() {} | 123 TemporalLayersListener() {} |
120 virtual ~TemporalLayersListener() {} | 124 virtual ~TemporalLayersListener() {} |
121 | 125 |
122 virtual void OnTemporalLayersCreated(int simulcast_id, | 126 virtual void OnTemporalLayersCreated(int simulcast_id, |
123 TemporalLayers* layers) = 0; | 127 TemporalLayers* layers) = 0; |
124 }; | 128 }; |
125 | 129 |
126 } // namespace webrtc | 130 } // namespace webrtc |
127 #endif // WEBRTC_MODULES_VIDEO_CODING_CODECS_VP8_TEMPORAL_LAYERS_H_ | 131 #endif // WEBRTC_MODULES_VIDEO_CODING_CODECS_VP8_TEMPORAL_LAYERS_H_ |
OLD | NEW |