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

Side by Side Diff: webrtc/modules/video_coding/codecs/vp8/simulcast_encoder_adapter_unittest.cc

Issue 2479643002: Revert of Remove deprected functions from EncodedImageCallback and RtpRtcp (Closed)
Patch Set: Created 4 years, 1 month 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) 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 134 matching lines...) Expand 10 before | Expand all | Expand 10 after
145 145
146 virtual ~MockVideoEncoder() {} 146 virtual ~MockVideoEncoder() {}
147 147
148 const VideoCodec& codec() const { return codec_; } 148 const VideoCodec& codec() const { return codec_; }
149 149
150 void SendEncodedImage(int width, int height) { 150 void SendEncodedImage(int width, int height) {
151 // Sends a fake image of the given width/height. 151 // Sends a fake image of the given width/height.
152 EncodedImage image; 152 EncodedImage image;
153 image._encodedWidth = width; 153 image._encodedWidth = width;
154 image._encodedHeight = height; 154 image._encodedHeight = height;
155 CodecSpecificInfo codec_specific_info; 155 CodecSpecificInfo codecSpecificInfo;
156 memset(&codec_specific_info, 0, sizeof(codec_specific_info)); 156 memset(&codecSpecificInfo, 0, sizeof(codecSpecificInfo));
157 callback_->OnEncodedImage(image, &codec_specific_info, NULL); 157 callback_->Encoded(image, &codecSpecificInfo, NULL);
158 } 158 }
159 159
160 void set_supports_native_handle(bool enabled) { 160 void set_supports_native_handle(bool enabled) {
161 supports_native_handle_ = enabled; 161 supports_native_handle_ = enabled;
162 } 162 }
163 int32_t last_set_bitrate() const { return last_set_bitrate_; } 163 int32_t last_set_bitrate() const { return last_set_bitrate_; }
164 164
165 MOCK_CONST_METHOD0(ImplementationName, const char*()); 165 MOCK_CONST_METHOD0(ImplementationName, const char*());
166 166
167 private: 167 private:
(...skipping 363 matching lines...) Expand 10 before | Expand all | Expand 10 after
531 kDefaultWidth, kDefaultHeight, kDefaultWidth, half_width, half_width); 531 kDefaultWidth, kDefaultHeight, kDefaultWidth, half_width, half_width);
532 input_buffer->InitializeData(); 532 input_buffer->InitializeData();
533 VideoFrame input_frame(input_buffer, 0, 0, webrtc::kVideoRotation_0); 533 VideoFrame input_frame(input_buffer, 0, 0, webrtc::kVideoRotation_0);
534 std::vector<FrameType> frame_types(3, kVideoFrameKey); 534 std::vector<FrameType> frame_types(3, kVideoFrameKey);
535 EXPECT_EQ(WEBRTC_VIDEO_CODEC_FALLBACK_SOFTWARE, 535 EXPECT_EQ(WEBRTC_VIDEO_CODEC_FALLBACK_SOFTWARE,
536 adapter_->Encode(input_frame, nullptr, &frame_types)); 536 adapter_->Encode(input_frame, nullptr, &frame_types));
537 } 537 }
538 538
539 } // namespace testing 539 } // namespace testing
540 } // namespace webrtc 540 } // namespace webrtc
OLDNEW
« no previous file with comments | « webrtc/modules/video_coding/codecs/i420/i420.cc ('k') | webrtc/modules/video_coding/codecs/vp8/vp8_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698