blob: e54bd437742847cd5d2acf7c6eb2b2aac6885798 [file] [log] [blame]
wu@webrtc.orgf3f2f6a2011-10-19 18:42:17 +00001/*
leozwang@webrtc.org1745e932012-03-01 16:30:40 +00002 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved.
wu@webrtc.orgf3f2f6a2011-10-19 18:42:17 +00003 *
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
6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree.
9 */
10
sergeyu@chromium.org099b8c92013-07-25 18:41:43 +000011#include "webrtc/modules/video_capture/device_info_impl.h"
12#include "webrtc/modules/video_capture/video_capture_impl.h"
wu@webrtc.orgf3f2f6a2011-10-19 18:42:17 +000013
14namespace webrtc {
15
16namespace videocapturemodule {
17
18class ExternalDeviceInfo : public DeviceInfoImpl {
19 public:
nisseb29b9c82016-12-12 00:22:56 -080020 ExternalDeviceInfo() {}
wu@webrtc.orgf3f2f6a2011-10-19 18:42:17 +000021 virtual ~ExternalDeviceInfo() {}
pbos@webrtc.orgdfc5bb92013-04-10 08:23:13 +000022 virtual uint32_t NumberOfDevices() { return 0; }
23 virtual int32_t DisplayCaptureSettingsDialogBox(
leozwang@webrtc.org3a392302012-03-12 21:03:38 +000024 const char* /*deviceUniqueIdUTF8*/,
25 const char* /*dialogTitleUTF8*/,
wu@webrtc.orgf3f2f6a2011-10-19 18:42:17 +000026 void* /*parentWindow*/,
pbos@webrtc.orgdfc5bb92013-04-10 08:23:13 +000027 uint32_t /*positionX*/,
28 uint32_t /*positionY*/) { return -1; }
29 virtual int32_t GetDeviceName(
30 uint32_t deviceNumber,
leozwang@webrtc.org1745e932012-03-01 16:30:40 +000031 char* deviceNameUTF8,
pbos@webrtc.orgdfc5bb92013-04-10 08:23:13 +000032 uint32_t deviceNameLength,
leozwang@webrtc.org1745e932012-03-01 16:30:40 +000033 char* deviceUniqueIdUTF8,
pbos@webrtc.orgdfc5bb92013-04-10 08:23:13 +000034 uint32_t deviceUniqueIdUTF8Length,
leozwang@webrtc.org1745e932012-03-01 16:30:40 +000035 char* productUniqueIdUTF8=0,
pbos@webrtc.orgdfc5bb92013-04-10 08:23:13 +000036 uint32_t productUniqueIdUTF8Length=0) {
wu@webrtc.orgf3f2f6a2011-10-19 18:42:17 +000037 return -1;
38 }
pbos@webrtc.orgdfc5bb92013-04-10 08:23:13 +000039 virtual int32_t CreateCapabilityMap(
leozwang@webrtc.org1745e932012-03-01 16:30:40 +000040 const char* deviceUniqueIdUTF8) { return 0; }
pbos@webrtc.orgdfc5bb92013-04-10 08:23:13 +000041 virtual int32_t Init() { return 0; }
wu@webrtc.orgf3f2f6a2011-10-19 18:42:17 +000042};
43
nisseb29b9c82016-12-12 00:22:56 -080044VideoCaptureModule::DeviceInfo* VideoCaptureImpl::CreateDeviceInfo() {
45 return new ExternalDeviceInfo();
wu@webrtc.orgf3f2f6a2011-10-19 18:42:17 +000046}
47
48} // namespace videocapturemodule
49
50} // namespace webrtc