Index: media/video/capture/video_capture_device.cc |
diff --git a/media/video/capture/video_capture_device.cc b/media/video/capture/video_capture_device.cc |
index c2b49cf1a16b44db1d3e20dc87c5faa0bfec0325..ca4cf09804df4d44f80780367ef8606c7b7ad7c2 100644 |
--- a/media/video/capture/video_capture_device.cc |
+++ b/media/video/capture/video_capture_device.cc |
@@ -25,6 +25,7 @@ VideoCaptureDevice::Name::Name(const std::string& name, const std::string& id) |
: device_name_(name), unique_id_(id) {} |
#if defined(OS_WIN) |
+ |
VideoCaptureDevice::Name::Name(const std::string& name, |
const std::string& id, |
const CaptureApiType api_type) |
@@ -32,9 +33,7 @@ VideoCaptureDevice::Name::Name(const std::string& name, |
unique_id_(id), |
capture_api_class_(api_type), |
capabilities_id_(id) {} |
-#endif |
- |
-#if defined(OS_MACOSX) |
+#elif defined(OS_MACOSX) |
VideoCaptureDevice::Name::Name(const std::string& name, |
const std::string& id, |
const CaptureApiType api_type) |
@@ -53,6 +52,13 @@ VideoCaptureDevice::Name::Name(const std::string& name, |
capture_api_class_(api_type), |
transport_type_(transport_type), |
is_blacklisted_(false) {} |
+#elif defined(ANDROID) |
+VideoCaptureDevice::Name::Name(const std::string& name, |
+ const std::string& id, |
+ const CaptureApiType api_type) |
+ : device_name_(name), |
+ unique_id_(id), |
+ capture_api_class_(api_type) {} |
#endif |
VideoCaptureDevice::Name::~Name() {} |
@@ -85,6 +91,25 @@ const char* VideoCaptureDevice::Name::GetCaptureApiTypeString() const { |
return "Unknown API"; |
} |
} |
+#elif defined(OS_ANDROID) |
+const char* VideoCaptureDevice::Name::GetCaptureApiTypeString() const { |
+ switch(capture_api_type()) { |
+ case API1: |
+ return "API1"; |
mcasas
2015/03/19 01:55:14
The human readable strings (and their counterparts
emircan
2015/03/19 19:52:23
I see. I am naming them "Camera API2 Full" like sp
|
+ case API2_FULL: |
+ return "API2_FULL"; |
+ case API2_LEGACY: |
+ return "API2_LEGACY"; |
+ case API2_LIMITED: |
+ return "API2_LIMITED"; |
+ case TANGO: |
+ return "TANGO"; |
+ case API_TYPE_UNKNOWN: |
+ default: |
+ NOTREACHED() << "Unknown Video Capture API type!"; |
+ return "Unknown API"; |
+ } |
+} |
#endif |
VideoCaptureDevice::~VideoCaptureDevice() {} |