| 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..70c24df0acdc4c8bd5d5e69faf3ce0513c3bae32 100644
|
| --- a/media/video/capture/video_capture_device.cc
|
| +++ b/media/video/capture/video_capture_device.cc
|
| @@ -24,7 +24,14 @@ VideoCaptureDevice::Name::Name() {}
|
| VideoCaptureDevice::Name::Name(const std::string& name, const std::string& id)
|
| : device_name_(name), unique_id_(id) {}
|
|
|
| -#if defined(OS_WIN)
|
| +#if defined(OS_LINUX)
|
| +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) {}
|
| +#elif defined(OS_WIN)
|
| VideoCaptureDevice::Name::Name(const std::string& name,
|
| const std::string& id,
|
| const CaptureApiType api_type)
|
| @@ -32,9 +39,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)
|
| @@ -57,7 +62,19 @@ VideoCaptureDevice::Name::Name(const std::string& name,
|
|
|
| VideoCaptureDevice::Name::~Name() {}
|
|
|
| -#if defined(OS_WIN)
|
| +#if defined(OS_LINUX)
|
| +const char* VideoCaptureDevice::Name::GetCaptureApiTypeString() const {
|
| + switch (capture_api_type()) {
|
| + case V4L2_SINGLE_PLANE:
|
| + return "V4L2 SPLANE";
|
| + case V4L2_MULTI_PLANE:
|
| + return "V4L2 MPLANE";
|
| + default:
|
| + NOTREACHED() << "Unknown Video Capture API type!";
|
| + return "Unknown API";
|
| + }
|
| +}
|
| +#elif defined(OS_WIN)
|
| const char* VideoCaptureDevice::Name::GetCaptureApiTypeString() const {
|
| switch(capture_api_type()) {
|
| case MEDIA_FOUNDATION:
|
|
|