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

Side by Side Diff: content/browser/media/webrtc_browsertest.cc

Issue 246433006: Change MediaStreamVideoSource to output different resolutions to different tracks depending on the … (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebased Created 6 years, 7 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | content/browser/media/webrtc_getusermedia_browsertest.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 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "base/command_line.h" 5 #include "base/command_line.h"
6 #include "base/file_util.h" 6 #include "base/file_util.h"
7 #include "base/strings/stringprintf.h" 7 #include "base/strings/stringprintf.h"
8 #include "base/threading/platform_thread.h" 8 #include "base/threading/platform_thread.h"
9 #include "base/values.h" 9 #include "base/values.h"
10 #include "content/browser/media/webrtc_internals.h" 10 #include "content/browser/media/webrtc_internals.h"
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
99 "callAndExpectResolution({video: true}, 640, 480);"); 99 "callAndExpectResolution({video: true}, 640, 480);");
100 } 100 }
101 101
102 IN_PROC_BROWSER_TEST_P(WebRtcBrowserTest, CanSetupVideoCallWith1To1AspecRatio) { 102 IN_PROC_BROWSER_TEST_P(WebRtcBrowserTest, CanSetupVideoCallWith1To1AspecRatio) {
103 const std::string javascript = 103 const std::string javascript =
104 "callAndExpectResolution({video: {mandatory: {minWidth: 320," 104 "callAndExpectResolution({video: {mandatory: {minWidth: 320,"
105 " maxWidth: 320, minHeight: 320, maxHeight: 320}}}, 320, 320);"; 105 " maxWidth: 320, minHeight: 320, maxHeight: 320}}}, 320, 320);";
106 MakeTypicalPeerConnectionCall(javascript); 106 MakeTypicalPeerConnectionCall(javascript);
107 } 107 }
108 108
109 IN_PROC_BROWSER_TEST_P(WebRtcBrowserTest,
110 CanSetupVideoCallWith16To9AspecRatio) {
111 const std::string javascript =
112 "callAndExpectResolution({video: {mandatory: {minWidth: 640,"
113 " maxWidth: 640, minAspectRatio: 1.777}}}, 640, 360);";
114 MakeTypicalPeerConnectionCall(javascript);
115 }
116
117 IN_PROC_BROWSER_TEST_P(WebRtcBrowserTest,
118 CanSetupVideoCallWith4To3AspecRatio) {
119 const std::string javascript =
120 "callAndExpectResolution({video: {mandatory: {minWidth: 960,"
121 "maxAspectRatio: 1.333}}}, 960, 720);";
122 MakeTypicalPeerConnectionCall(javascript);
123 }
124
109 #if defined(OS_LINUX) && !defined(OS_CHROMEOS) && defined(ARCH_CPU_ARM_FAMILY) 125 #if defined(OS_LINUX) && !defined(OS_CHROMEOS) && defined(ARCH_CPU_ARM_FAMILY)
110 // Timing out on ARM linux, see http://crbug.com/240376 126 // Timing out on ARM linux, see http://crbug.com/240376
111 #define MAYBE_CanSetupAudioAndVideoCall DISABLED_CanSetupAudioAndVideoCall 127 #define MAYBE_CanSetupAudioAndVideoCall DISABLED_CanSetupAudioAndVideoCall
112 #else 128 #else
113 #define MAYBE_CanSetupAudioAndVideoCall CanSetupAudioAndVideoCall 129 #define MAYBE_CanSetupAudioAndVideoCall CanSetupAudioAndVideoCall
114 #endif 130 #endif
115 131
116 IN_PROC_BROWSER_TEST_P(WebRtcBrowserTest, MAYBE_CanSetupAudioAndVideoCall) { 132 IN_PROC_BROWSER_TEST_P(WebRtcBrowserTest, MAYBE_CanSetupAudioAndVideoCall) {
117 MakeTypicalPeerConnectionCall("call({video: true, audio: true});"); 133 MakeTypicalPeerConnectionCall("call({video: true, audio: true});");
118 } 134 }
(...skipping 327 matching lines...) Expand 10 before | Expand all | Expand 10 after
446 462
447 EXPECT_TRUE(base::PathExists(dump_file)); 463 EXPECT_TRUE(base::PathExists(dump_file));
448 int64 file_size = 0; 464 int64 file_size = 0;
449 EXPECT_TRUE(base::GetFileSize(dump_file, &file_size)); 465 EXPECT_TRUE(base::GetFileSize(dump_file, &file_size));
450 EXPECT_EQ(0, file_size); 466 EXPECT_EQ(0, file_size);
451 467
452 base::DeleteFile(dump_file, false); 468 base::DeleteFile(dump_file, false);
453 } 469 }
454 470
455 } // namespace content 471 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | content/browser/media/webrtc_getusermedia_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698