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

Unified Diff: media/capture/video/mac/video_capture_device_mac.h

Issue 2169013002: Change class VideoCaptureDevice::Name to struct VideoCaptureDeviceDescriptor (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix build errors Created 4 years, 5 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: media/capture/video/mac/video_capture_device_mac.h
diff --git a/media/capture/video/mac/video_capture_device_mac.h b/media/capture/video/mac/video_capture_device_mac.h
index 7eff128ab1e0b50ee05c893364027f5625fb78af..c084ba1bc4fd3e0ad2a5472369a6a0bbec6e50d3 100644
--- a/media/capture/video/mac/video_capture_device_mac.h
+++ b/media/capture/video/mac/video_capture_device_mac.h
@@ -54,7 +54,8 @@ namespace media {
// capture devices.
class VideoCaptureDeviceMac : public VideoCaptureDevice {
public:
- explicit VideoCaptureDeviceMac(const Name& device_name);
+ explicit VideoCaptureDeviceMac(
+ const VideoCaptureDeviceDescriptor& device_descriptor);
~VideoCaptureDeviceMac() override;
// VideoCaptureDevice implementation.
@@ -64,7 +65,7 @@ class VideoCaptureDeviceMac : public VideoCaptureDevice {
void StopAndDeAllocate() override;
void TakePhoto(TakePhotoCallback callback) override;
- bool Init(VideoCaptureDevice::Name::CaptureApiType capture_api_type);
+ bool Init(VideoCaptureApi capture_api_type);
// Called to deliver captured video frames. It's safe to call this method
// from any thread, including those controlled by AVFoundation.
@@ -89,6 +90,10 @@ class VideoCaptureDeviceMac : public VideoCaptureDevice {
// Forwarder to VideoCaptureDevice::Client::OnLog().
void LogMessage(const std::string& message);
+ static std::string GetDeviceModelId(const std::string& device_id,
+ VideoCaptureApi capture_api,
+ VideoCaptureTransportType transport_type);
+
private:
void SetErrorState(const tracked_objects::Location& from_here,
const std::string& reason);
@@ -97,7 +102,7 @@ class VideoCaptureDeviceMac : public VideoCaptureDevice {
// Flag indicating the internal state.
enum InternalState { kNotInitialized, kIdle, kCapturing, kError };
- Name device_name_;
+ VideoCaptureDeviceDescriptor device_descriptor_;
std::unique_ptr<VideoCaptureDevice::Client> client_;
VideoCaptureFormat capture_format_;

Powered by Google App Engine
This is Rietveld 408576698