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

Side by Side Diff: content/browser/renderer_host/media/desktop_capture_device_unittest.cc

Issue 134633004: Roll libjingle+webrtc to r5397. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 6 years, 11 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
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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 "content/browser/renderer_host/media/desktop_capture_device.h" 5 #include "content/browser/renderer_host/media/desktop_capture_device.h"
6 6
7 #include "base/basictypes.h" 7 #include "base/basictypes.h"
8 #include "base/sequenced_task_runner.h" 8 #include "base/sequenced_task_runner.h"
9 #include "base/synchronization/waitable_event.h" 9 #include "base/synchronization/waitable_event.h"
10 #include "base/test/test_timeouts.h" 10 #include "base/test/test_timeouts.h"
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after
112 webrtc::DesktopFrame* frame = new webrtc::BasicDesktopFrame(size); 112 webrtc::DesktopFrame* frame = new webrtc::BasicDesktopFrame(size);
113 if (generate_inverted_frames_) 113 if (generate_inverted_frames_)
114 frame = new InvertedDesktopFrame(frame); 114 frame = new InvertedDesktopFrame(frame);
115 callback_->OnCaptureCompleted(frame); 115 callback_->OnCaptureCompleted(frame);
116 } 116 }
117 117
118 virtual void SetMouseShapeObserver( 118 virtual void SetMouseShapeObserver(
119 MouseShapeObserver* mouse_shape_observer) OVERRIDE { 119 MouseShapeObserver* mouse_shape_observer) OVERRIDE {
120 } 120 }
121 121
122 virtual bool GetScreenList(ScreenList* screens) OVERRIDE {
123 return false;
124 }
125
126 virtual bool SelectScreen(webrtc::ScreenId id) OVERRIDE {
127 return false;
128 }
129
122 private: 130 private:
123 Callback* callback_; 131 Callback* callback_;
124 int frame_index_; 132 int frame_index_;
125 bool generate_inverted_frames_; 133 bool generate_inverted_frames_;
126 }; 134 };
127 135
128 class DesktopCaptureDeviceTest : public testing::Test { 136 class DesktopCaptureDeviceTest : public testing::Test {
129 public: 137 public:
130 virtual void SetUp() OVERRIDE { 138 virtual void SetUp() OVERRIDE {
131 worker_pool_ = new base::SequencedWorkerPool(3, "TestCaptureThread"); 139 worker_pool_ = new base::SequencedWorkerPool(3, "TestCaptureThread");
(...skipping 138 matching lines...) Expand 10 before | Expand all | Expand 10 after
270 capture_device.StopAndDeAllocate(); 278 capture_device.StopAndDeAllocate();
271 279
272 EXPECT_EQ(kTestFrameWidth1, format.frame_size.width()); 280 EXPECT_EQ(kTestFrameWidth1, format.frame_size.width());
273 EXPECT_EQ(kTestFrameHeight1, format.frame_size.height()); 281 EXPECT_EQ(kTestFrameHeight1, format.frame_size.height());
274 EXPECT_EQ(kFrameRate, format.frame_rate); 282 EXPECT_EQ(kFrameRate, format.frame_rate);
275 EXPECT_EQ(media::PIXEL_FORMAT_ARGB, format.pixel_format); 283 EXPECT_EQ(media::PIXEL_FORMAT_ARGB, format.pixel_format);
276 worker_pool_->FlushForTesting(); 284 worker_pool_->FlushForTesting();
277 } 285 }
278 286
279 } // namespace content 287 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/renderer_host/media/desktop_capture_device.cc ('k') | content/renderer/media/rtc_media_constraints.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698