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

Unified Diff: services/video_capture/public/cpp/capture_settings.h

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/public/cpp/capture_settings.h
diff --git a/services/video_capture/public/cpp/capture_settings.h b/services/video_capture/public/cpp/capture_settings.h
deleted file mode 100644
index 38d0ec32343b3bed54a20eb542ba07ca1f1c72f2..0000000000000000000000000000000000000000
--- a/services/video_capture/public/cpp/capture_settings.h
+++ /dev/null
@@ -1,47 +0,0 @@
-// Copyright 2016 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef SERVICES_VIDEO_CAPTURE_PUBLIC_CPP_CAPTURE_SETTINGS_H_
-#define SERVICES_VIDEO_CAPTURE_PUBLIC_CPP_CAPTURE_SETTINGS_H_
-
-#include "media/capture/video_capture_types.h"
-#include "ui/gfx/geometry/size.h"
-
-namespace video_capture {
-
-// Cpp equivalent of Mojo struct video_capture::mojom::CaptureFormat.
-struct I420CaptureFormat {
- gfx::Size frame_size;
- float frame_rate;
-
- bool operator==(const I420CaptureFormat& other) const {
- return frame_size == other.frame_size && frame_rate == other.frame_rate;
- }
-
- void ConvertToMediaVideoCaptureFormat(
- media::VideoCaptureFormat* target) const {
- target->frame_size = frame_size;
- target->frame_rate = frame_rate;
- target->pixel_format = media::PIXEL_FORMAT_I420;
- target->pixel_storage = media::PIXEL_STORAGE_CPU;
- }
-};
-
-// Cpp equivalent of Mojo struct video_capture::mojom::CaptureSettings.
-struct CaptureSettings {
- I420CaptureFormat format;
- media::ResolutionChangePolicy resolution_change_policy;
- media::PowerLineFrequency power_line_frequency;
-
- void ConvertToMediaVideoCaptureParams(
- media::VideoCaptureParams* target) const {
- format.ConvertToMediaVideoCaptureFormat(&(target->requested_format));
- target->resolution_change_policy = resolution_change_policy;
- target->power_line_frequency = power_line_frequency;
- }
-};
-
-} // namespace video_capture
-
-#endif // SERVICES_VIDEO_CAPTURE_PUBLIC_CPP_CAPTURE_SETTINGS_H_
« no previous file with comments | « services/video_capture/device_media_to_mojo_adapter.cc ('k') | services/video_capture/public/interfaces/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698