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

Unified Diff: trunk/src/content/browser/renderer_host/media/video_capture_host_unittest.cc

Issue 84393002: Revert 236927 "Reorganize media::VideoCapture* types" (Closed) Base URL: svn://svn.chromium.org/chrome/
Patch Set: Created 7 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 side-by-side diff with in-line comments
Download patch
Index: trunk/src/content/browser/renderer_host/media/video_capture_host_unittest.cc
===================================================================
--- trunk/src/content/browser/renderer_host/media/video_capture_host_unittest.cc (revision 236934)
+++ trunk/src/content/browser/renderer_host/media/video_capture_host_unittest.cc (working copy)
@@ -199,14 +199,13 @@
ASSERT_TRUE(dib != NULL);
if (dump_video_) {
if (!format_.IsValid()) {
- dumper_.StartDump(frame_format.frame_size.width(),
- frame_format.frame_size.height());
+ dumper_.StartDump(frame_format.width, frame_format.height);
format_ = frame_format;
}
- ASSERT_EQ(format_.frame_size.width(), frame_format.frame_size.width())
+ ASSERT_EQ(format_.width, frame_format.width)
<< "Dump format does not handle variable resolution.";
- ASSERT_EQ(format_.frame_size.height(), frame_format.frame_size.height())
- << "Dump format does not handle variable resolution.";
+ ASSERT_EQ(format_.height, frame_format.height)
+ << "Dump format does not handle variable resolution.";;
dumper_.NewVideoFrame(dib->memory());
}
@@ -348,8 +347,9 @@
media::VideoCaptureParams params;
params.requested_format = media::VideoCaptureFormat(
- gfx::Size(352, 288), 30, media::PIXEL_FORMAT_I420);
- host_->OnStartCapture(kDeviceId, opened_session_id_, params);
+ 352, 288, 30, media::ConstantResolutionVideoCaptureDevice);
+ params.session_id = opened_session_id_;
+ host_->OnStartCapture(kDeviceId, params);
run_loop.Run();
}
@@ -361,8 +361,9 @@
EXPECT_CALL(*host_, OnStateChanged(kDeviceId, VIDEO_CAPTURE_STATE_STOPPED));
media::VideoCaptureParams params;
params.requested_format = media::VideoCaptureFormat(
- gfx::Size(352, 288), 30, media::PIXEL_FORMAT_I420);
- host_->OnStartCapture(kDeviceId, opened_session_id_, params);
+ 352, 288, 30, media::ConstantResolutionVideoCaptureDevice);
+ params.session_id = opened_session_id_;
+ host_->OnStartCapture(kDeviceId, params);
host_->OnStopCapture(kDeviceId);
run_loop.RunUntilIdle();
}
@@ -379,10 +380,11 @@
.WillOnce(ExitMessageLoop(message_loop_, run_loop.QuitClosure()));
media::VideoCaptureParams params;
- params.requested_format =
- media::VideoCaptureFormat(gfx::Size(width, height), frame_rate);
+ params.requested_format = media::VideoCaptureFormat(
+ width, height, frame_rate, media::ConstantResolutionVideoCaptureDevice);
+ params.session_id = opened_session_id_;
host_->SetDumpVideo(true);
- host_->OnStartCapture(kDeviceId, opened_session_id_, params);
+ host_->OnStartCapture(kDeviceId, params);
run_loop.Run();
}
#endif

Powered by Google App Engine
This is Rietveld 408576698