1 | /* $Id: HostVideoInputDeviceImpl.h 93115 2022-01-01 11:31:46Z vboxsync $ */
|
---|
2 | /** @file
|
---|
3 | * A host video capture device description.
|
---|
4 | */
|
---|
5 |
|
---|
6 | /*
|
---|
7 | * Copyright (C) 2013-2022 Oracle Corporation
|
---|
8 | *
|
---|
9 | * This file is part of VirtualBox Open Source Edition (OSE), as
|
---|
10 | * available from http://www.virtualbox.org. This file is free software;
|
---|
11 | * you can redistribute it and/or modify it under the terms of the GNU
|
---|
12 | * General Public License (GPL) as published by the Free Software
|
---|
13 | * Foundation, in version 2 as it comes in the "COPYING" file of the
|
---|
14 | * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
|
---|
15 | * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
|
---|
16 | */
|
---|
17 |
|
---|
18 | #ifndef MAIN_INCLUDED_HostVideoInputDeviceImpl_h
|
---|
19 | #define MAIN_INCLUDED_HostVideoInputDeviceImpl_h
|
---|
20 | #ifndef RT_WITHOUT_PRAGMA_ONCE
|
---|
21 | # pragma once
|
---|
22 | #endif
|
---|
23 |
|
---|
24 | #include "HostVideoInputDeviceWrap.h"
|
---|
25 |
|
---|
26 | #include <list>
|
---|
27 |
|
---|
28 | class HostVideoInputDevice;
|
---|
29 |
|
---|
30 | typedef std::list<ComObjPtr<HostVideoInputDevice> > HostVideoInputDeviceList;
|
---|
31 |
|
---|
32 | class ATL_NO_VTABLE HostVideoInputDevice :
|
---|
33 | public HostVideoInputDeviceWrap
|
---|
34 | {
|
---|
35 | public:
|
---|
36 |
|
---|
37 | DECLARE_COMMON_CLASS_METHODS(HostVideoInputDevice)
|
---|
38 |
|
---|
39 | HRESULT FinalConstruct();
|
---|
40 | void FinalRelease();
|
---|
41 |
|
---|
42 | /* Public initializer/uninitializer for internal purposes only. */
|
---|
43 | HRESULT init(const com::Utf8Str &name, const com::Utf8Str &path, const com::Utf8Str &alias);
|
---|
44 | void uninit();
|
---|
45 |
|
---|
46 | static HRESULT queryHostDevices(VirtualBox *pVirtualBox, HostVideoInputDeviceList *pList);
|
---|
47 |
|
---|
48 | private:
|
---|
49 |
|
---|
50 | // wrapped IHostVideoInputDevice properties
|
---|
51 | virtual HRESULT getName(com::Utf8Str &aName) { aName = m.name; return S_OK; }
|
---|
52 | virtual HRESULT getPath(com::Utf8Str &aPath) { aPath = m.path; return S_OK; }
|
---|
53 | virtual HRESULT getAlias(com::Utf8Str &aAlias) { aAlias = m.alias; return S_OK; }
|
---|
54 |
|
---|
55 | /* Data. */
|
---|
56 | struct Data
|
---|
57 | {
|
---|
58 | Data()
|
---|
59 | {
|
---|
60 | }
|
---|
61 |
|
---|
62 | com::Utf8Str name;
|
---|
63 | com::Utf8Str path;
|
---|
64 | com::Utf8Str alias;
|
---|
65 | };
|
---|
66 |
|
---|
67 | Data m;
|
---|
68 | };
|
---|
69 |
|
---|
70 | #endif /* !MAIN_INCLUDED_HostVideoInputDeviceImpl_h */
|
---|
71 |
|
---|
72 | /* vi: set tabstop=4 shiftwidth=4 expandtab: */
|
---|