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

Side by Side Diff: webrtc/video/video_send_stream_tests.cc

Issue 2986893002: Piggybacking simulcast id and ALR experiment id into video content type extension. (Closed)
Patch Set: use namespace instead of struct Created 3 years, 3 months 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/receive_statistics_proxy_unittest.cc ('k') | webrtc/video/video_stream_decoder.h » ('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 300 matching lines...) Expand 10 before | Expand all | Expand 10 after
311 kRtpExtensionVideoContentType, test::kVideoContentTypeExtensionId)); 311 kRtpExtensionVideoContentType, test::kVideoContentTypeExtensionId));
312 } 312 }
313 313
314 Action OnSendRtp(const uint8_t* packet, size_t length) override { 314 Action OnSendRtp(const uint8_t* packet, size_t length) override {
315 RTPHeader header; 315 RTPHeader header;
316 EXPECT_TRUE(parser_->Parse(packet, length, &header)); 316 EXPECT_TRUE(parser_->Parse(packet, length, &header));
317 // Only the last packet of the frame must have extension. 317 // Only the last packet of the frame must have extension.
318 if (!header.markerBit) 318 if (!header.markerBit)
319 return SEND_PACKET; 319 return SEND_PACKET;
320 EXPECT_TRUE(header.extension.hasVideoContentType); 320 EXPECT_TRUE(header.extension.hasVideoContentType);
321 EXPECT_EQ(VideoContentType::SCREENSHARE, 321 EXPECT_TRUE(videocontenttypehelpers::IsScreenshare(
322 header.extension.videoContentType); 322 header.extension.videoContentType));
323 observation_complete_.Set(); 323 observation_complete_.Set();
324 return SEND_PACKET; 324 return SEND_PACKET;
325 } 325 }
326 326
327 void ModifyVideoConfigs( 327 void ModifyVideoConfigs(
328 VideoSendStream::Config* send_config, 328 VideoSendStream::Config* send_config,
329 std::vector<VideoReceiveStream::Config>* receive_configs, 329 std::vector<VideoReceiveStream::Config>* receive_configs,
330 VideoEncoderConfig* encoder_config) override { 330 VideoEncoderConfig* encoder_config) override {
331 send_config->rtp.extensions.clear(); 331 send_config->rtp.extensions.clear();
332 send_config->rtp.extensions.push_back( 332 send_config->rtp.extensions.push_back(
(...skipping 3171 matching lines...) Expand 10 before | Expand all | Expand 10 after
3504 capturer_ = frame_generator_capturer; 3504 capturer_ = frame_generator_capturer;
3505 } 3505 }
3506 3506
3507 test::FrameGeneratorCapturer* capturer_ = nullptr; 3507 test::FrameGeneratorCapturer* capturer_ = nullptr;
3508 } test; 3508 } test;
3509 3509
3510 RunBaseTest(&test); 3510 RunBaseTest(&test);
3511 } 3511 }
3512 3512
3513 } // namespace webrtc 3513 } // namespace webrtc
OLDNEW
« no previous file with comments | « webrtc/video/receive_statistics_proxy_unittest.cc ('k') | webrtc/video/video_stream_decoder.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698