| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. |
| 3 * | 3 * |
| 4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
| 5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
| 6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
| 7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
| 8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
| 9 */ | 9 */ |
| 10 | 10 |
| 11 #include "webrtc/modules/video_capture/device_info_impl.h" | 11 #include "webrtc/modules/video_capture/device_info_impl.h" |
| 12 #include "webrtc/modules/video_capture/video_capture_impl.h" | 12 #include "webrtc/modules/video_capture/video_capture_impl.h" |
| 13 | 13 |
| 14 namespace webrtc { | 14 namespace webrtc { |
| 15 | 15 |
| 16 namespace videocapturemodule { | 16 namespace videocapturemodule { |
| 17 | 17 |
| 18 class ExternalDeviceInfo : public DeviceInfoImpl { | 18 class ExternalDeviceInfo : public DeviceInfoImpl { |
| 19 public: | 19 public: |
| 20 ExternalDeviceInfo(const int32_t id) | 20 ExternalDeviceInfo() {} |
| 21 : DeviceInfoImpl(id) { | |
| 22 } | |
| 23 virtual ~ExternalDeviceInfo() {} | 21 virtual ~ExternalDeviceInfo() {} |
| 24 virtual uint32_t NumberOfDevices() { return 0; } | 22 virtual uint32_t NumberOfDevices() { return 0; } |
| 25 virtual int32_t DisplayCaptureSettingsDialogBox( | 23 virtual int32_t DisplayCaptureSettingsDialogBox( |
| 26 const char* /*deviceUniqueIdUTF8*/, | 24 const char* /*deviceUniqueIdUTF8*/, |
| 27 const char* /*dialogTitleUTF8*/, | 25 const char* /*dialogTitleUTF8*/, |
| 28 void* /*parentWindow*/, | 26 void* /*parentWindow*/, |
| 29 uint32_t /*positionX*/, | 27 uint32_t /*positionX*/, |
| 30 uint32_t /*positionY*/) { return -1; } | 28 uint32_t /*positionY*/) { return -1; } |
| 31 virtual int32_t GetDeviceName( | 29 virtual int32_t GetDeviceName( |
| 32 uint32_t deviceNumber, | 30 uint32_t deviceNumber, |
| 33 char* deviceNameUTF8, | 31 char* deviceNameUTF8, |
| 34 uint32_t deviceNameLength, | 32 uint32_t deviceNameLength, |
| 35 char* deviceUniqueIdUTF8, | 33 char* deviceUniqueIdUTF8, |
| 36 uint32_t deviceUniqueIdUTF8Length, | 34 uint32_t deviceUniqueIdUTF8Length, |
| 37 char* productUniqueIdUTF8=0, | 35 char* productUniqueIdUTF8=0, |
| 38 uint32_t productUniqueIdUTF8Length=0) { | 36 uint32_t productUniqueIdUTF8Length=0) { |
| 39 return -1; | 37 return -1; |
| 40 } | 38 } |
| 41 virtual int32_t CreateCapabilityMap( | 39 virtual int32_t CreateCapabilityMap( |
| 42 const char* deviceUniqueIdUTF8) { return 0; } | 40 const char* deviceUniqueIdUTF8) { return 0; } |
| 43 virtual int32_t Init() { return 0; } | 41 virtual int32_t Init() { return 0; } |
| 44 }; | 42 }; |
| 45 | 43 |
| 46 VideoCaptureModule::DeviceInfo* VideoCaptureImpl::CreateDeviceInfo( | 44 VideoCaptureModule::DeviceInfo* VideoCaptureImpl::CreateDeviceInfo() { |
| 47 const int32_t id) { | 45 return new ExternalDeviceInfo(); |
| 48 return new ExternalDeviceInfo(id); | |
| 49 } | 46 } |
| 50 | 47 |
| 51 } // namespace videocapturemodule | 48 } // namespace videocapturemodule |
| 52 | 49 |
| 53 } // namespace webrtc | 50 } // namespace webrtc |
| OLD | NEW |