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

Side by Side Diff: webrtc/video/video_send_stream_tests.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
« no previous file with comments | « webrtc/video/payload_router_unittest.cc ('k') | webrtc/video/vie_encoder_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2013 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2013 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 #include <algorithm> // max 10 #include <algorithm> // max
(...skipping 2379 matching lines...) Expand 10 before | Expand all | Expand 10 after
2390 EncodedImage encoded(buffer, sizeof(buffer), sizeof(buffer)); 2390 EncodedImage encoded(buffer, sizeof(buffer), sizeof(buffer));
2391 encoded._timeStamp = input_image.timestamp(); 2391 encoded._timeStamp = input_image.timestamp();
2392 encoded.capture_time_ms_ = input_image.render_time_ms(); 2392 encoded.capture_time_ms_ = input_image.render_time_ms();
2393 2393
2394 for (size_t i = 0; i < kNumStreams; ++i) { 2394 for (size_t i = 0; i < kNumStreams; ++i) {
2395 specifics.codecSpecific.generic.simulcast_idx = static_cast<uint8_t>(i); 2395 specifics.codecSpecific.generic.simulcast_idx = static_cast<uint8_t>(i);
2396 encoded._frameType = (*frame_types)[i]; 2396 encoded._frameType = (*frame_types)[i];
2397 encoded._encodedWidth = kEncodedResolution[i].width; 2397 encoded._encodedWidth = kEncodedResolution[i].width;
2398 encoded._encodedHeight = kEncodedResolution[i].height; 2398 encoded._encodedHeight = kEncodedResolution[i].height;
2399 RTC_DCHECK(callback_); 2399 RTC_DCHECK(callback_);
2400 if (callback_->OnEncodedImage(encoded, &specifics, nullptr).error != 2400 if (callback_->Encoded(encoded, &specifics, nullptr) != 0)
2401 EncodedImageCallback::Result::OK) {
2402 return -1; 2401 return -1;
2403 }
2404 } 2402 }
2405 2403
2406 observation_complete_.Set(); 2404 observation_complete_.Set();
2407 return 0; 2405 return 0;
2408 } 2406 }
2409 void ModifyVideoConfigs( 2407 void ModifyVideoConfigs(
2410 VideoSendStream::Config* send_config, 2408 VideoSendStream::Config* send_config,
2411 std::vector<VideoReceiveStream::Config>* receive_configs, 2409 std::vector<VideoReceiveStream::Config>* receive_configs,
2412 VideoEncoderConfig* encoder_config) override { 2410 VideoEncoderConfig* encoder_config) override {
2413 send_config->encoder_settings.encoder = this; 2411 send_config->encoder_settings.encoder = this;
(...skipping 476 matching lines...) Expand 10 before | Expand all | Expand 10 after
2890 observation_complete_.Set(); 2888 observation_complete_.Set();
2891 } 2889 }
2892 } 2890 }
2893 } test; 2891 } test;
2894 2892
2895 RunBaseTest(&test); 2893 RunBaseTest(&test);
2896 } 2894 }
2897 #endif // !defined(RTC_DISABLE_VP9) 2895 #endif // !defined(RTC_DISABLE_VP9)
2898 2896
2899 } // namespace webrtc 2897 } // namespace webrtc
OLDNEW
« no previous file with comments | « webrtc/video/payload_router_unittest.cc ('k') | webrtc/video/vie_encoder_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698