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

Side by Side Diff: webrtc/modules/video_coding/codecs/vp8/vp8_impl.h

Issue 2398963003: Move usage of QualityScaler to ViEEncoder. (Closed)
Patch Set: rebase Created 4 years 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) 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 * WEBRTC VP8 wrapper interface 10 * WEBRTC VP8 wrapper interface
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 const CodecSpecificInfo* codec_specific_info, 50 const CodecSpecificInfo* codec_specific_info,
51 const std::vector<FrameType>* frame_types) override; 51 const std::vector<FrameType>* frame_types) override;
52 52
53 int RegisterEncodeCompleteCallback(EncodedImageCallback* callback) override; 53 int RegisterEncodeCompleteCallback(EncodedImageCallback* callback) override;
54 54
55 int SetChannelParameters(uint32_t packet_loss, int64_t rtt) override; 55 int SetChannelParameters(uint32_t packet_loss, int64_t rtt) override;
56 56
57 int SetRateAllocation(const BitrateAllocation& bitrate, 57 int SetRateAllocation(const BitrateAllocation& bitrate,
58 uint32_t new_framerate) override; 58 uint32_t new_framerate) override;
59 59
60 void OnDroppedFrame() override; 60 ScalingSettings GetScalingSettings() const override;
61 61
62 const char* ImplementationName() const override; 62 const char* ImplementationName() const override;
63 63
64 private: 64 private:
65 void SetupTemporalLayers(int num_streams, 65 void SetupTemporalLayers(int num_streams,
66 int num_temporal_layers, 66 int num_temporal_layers,
67 const VideoCodec& codec); 67 const VideoCodec& codec);
68 68
69 // Set the cpu_speed setting for encoder based on resolution and/or platform. 69 // Set the cpu_speed setting for encoder based on resolution and/or platform.
70 int SetCpuSpeed(int width, int height); 70 int SetCpuSpeed(int width, int height);
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
109 std::vector<uint16_t> picture_id_; 109 std::vector<uint16_t> picture_id_;
110 std::vector<int> last_key_frame_picture_id_; 110 std::vector<int> last_key_frame_picture_id_;
111 std::vector<bool> key_frame_request_; 111 std::vector<bool> key_frame_request_;
112 std::vector<bool> send_stream_; 112 std::vector<bool> send_stream_;
113 std::vector<int> cpu_speed_; 113 std::vector<int> cpu_speed_;
114 std::vector<vpx_image_t> raw_images_; 114 std::vector<vpx_image_t> raw_images_;
115 std::vector<EncodedImage> encoded_images_; 115 std::vector<EncodedImage> encoded_images_;
116 std::vector<vpx_codec_ctx_t> encoders_; 116 std::vector<vpx_codec_ctx_t> encoders_;
117 std::vector<vpx_codec_enc_cfg_t> configurations_; 117 std::vector<vpx_codec_enc_cfg_t> configurations_;
118 std::vector<vpx_rational_t> downsampling_factors_; 118 std::vector<vpx_rational_t> downsampling_factors_;
119 QualityScaler quality_scaler_;
120 bool quality_scaler_enabled_;
121 }; // end of VP8EncoderImpl class 119 }; // end of VP8EncoderImpl class
122 120
123 class VP8DecoderImpl : public VP8Decoder { 121 class VP8DecoderImpl : public VP8Decoder {
124 public: 122 public:
125 VP8DecoderImpl(); 123 VP8DecoderImpl();
126 124
127 virtual ~VP8DecoderImpl(); 125 virtual ~VP8DecoderImpl();
128 126
129 int InitDecode(const VideoCodec* inst, int number_of_cores) override; 127 int InitDecode(const VideoCodec* inst, int number_of_cores) override;
130 128
(...skipping 30 matching lines...) Expand all
161 int image_format_; 159 int image_format_;
162 vpx_ref_frame_t* ref_frame_; 160 vpx_ref_frame_t* ref_frame_;
163 int propagation_cnt_; 161 int propagation_cnt_;
164 int last_frame_width_; 162 int last_frame_width_;
165 int last_frame_height_; 163 int last_frame_height_;
166 bool key_frame_required_; 164 bool key_frame_required_;
167 }; // end of VP8DecoderImpl class 165 }; // end of VP8DecoderImpl class
168 } // namespace webrtc 166 } // namespace webrtc
169 167
170 #endif // WEBRTC_MODULES_VIDEO_CODING_CODECS_VP8_VP8_IMPL_H_ 168 #endif // WEBRTC_MODULES_VIDEO_CODING_CODECS_VP8_VP8_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698