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

Unified Diff: services/video_capture/device_media_to_mojo_adapter.cc

Issue 2813343002: [Mojo Video Capture] Switch to using Mojo structs in media/capture/mojo (Closed)
Patch Set: Removed extraneous AtLeast Created 3 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: services/video_capture/device_media_to_mojo_adapter.cc
diff --git a/services/video_capture/device_media_to_mojo_adapter.cc b/services/video_capture/device_media_to_mojo_adapter.cc
index 6f6bf77f5c06783bae93a8c5dff5b85547d8a50f..a68c87fbb6b1e19c1fd14cebd438103079f7631b 100644
--- a/services/video_capture/device_media_to_mojo_adapter.cc
+++ b/services/video_capture/device_media_to_mojo_adapter.cc
@@ -25,10 +25,9 @@ DeviceMediaToMojoAdapter::~DeviceMediaToMojoAdapter() {
Stop();
}
-void DeviceMediaToMojoAdapter::Start(const CaptureSettings& requested_settings,
- mojom::ReceiverPtr receiver) {
- media::VideoCaptureParams params;
- requested_settings.ConvertToMediaVideoCaptureParams(&params);
+void DeviceMediaToMojoAdapter::Start(
+ const media::VideoCaptureParams& requested_settings,
+ mojom::ReceiverPtr receiver) {
receiver.set_connection_error_handler(
base::Bind(&DeviceMediaToMojoAdapter::OnClientConnectionErrorOrClose,
base::Unretained(this)));
@@ -47,7 +46,7 @@ void DeviceMediaToMojoAdapter::Start(const CaptureSettings& requested_settings,
auto device_client = base::MakeUnique<media::VideoCaptureDeviceClient>(
std::move(media_receiver), buffer_pool, jpeg_decoder_factory_callback_);
- device_->AllocateAndStart(params, std::move(device_client));
+ device_->AllocateAndStart(requested_settings, std::move(device_client));
device_running_ = true;
}
« no previous file with comments | « services/video_capture/device_media_to_mojo_adapter.h ('k') | services/video_capture/public/cpp/capture_settings.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698