[48578] | 1 | /* $Id: HostVideoInputDeviceImpl.h 98103 2023-01-17 14:15:46Z vboxsync $ */
|
---|
| 2 | /** @file
|
---|
| 3 | * A host video capture device description.
|
---|
| 4 | */
|
---|
| 5 |
|
---|
| 6 | /*
|
---|
[98103] | 7 | * Copyright (C) 2013-2023 Oracle and/or its affiliates.
|
---|
[48578] | 8 | *
|
---|
[96407] | 9 | * This file is part of VirtualBox base platform packages, as
|
---|
| 10 | * available from https://www.virtualbox.org.
|
---|
| 11 | *
|
---|
| 12 | * This program is free software; you can redistribute it and/or
|
---|
| 13 | * modify it under the terms of the GNU General Public License
|
---|
| 14 | * as published by the Free Software Foundation, in version 3 of the
|
---|
| 15 | * License.
|
---|
| 16 | *
|
---|
| 17 | * This program is distributed in the hope that it will be useful, but
|
---|
| 18 | * WITHOUT ANY WARRANTY; without even the implied warranty of
|
---|
| 19 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
---|
| 20 | * General Public License for more details.
|
---|
| 21 | *
|
---|
| 22 | * You should have received a copy of the GNU General Public License
|
---|
| 23 | * along with this program; if not, see <https://www.gnu.org/licenses>.
|
---|
| 24 | *
|
---|
| 25 | * SPDX-License-Identifier: GPL-3.0-only
|
---|
[48578] | 26 | */
|
---|
| 27 |
|
---|
[76562] | 28 | #ifndef MAIN_INCLUDED_HostVideoInputDeviceImpl_h
|
---|
| 29 | #define MAIN_INCLUDED_HostVideoInputDeviceImpl_h
|
---|
[76487] | 30 | #ifndef RT_WITHOUT_PRAGMA_ONCE
|
---|
| 31 | # pragma once
|
---|
| 32 | #endif
|
---|
[48578] | 33 |
|
---|
[48607] | 34 | #include "HostVideoInputDeviceWrap.h"
|
---|
[48578] | 35 |
|
---|
| 36 | #include <list>
|
---|
| 37 |
|
---|
[48607] | 38 | class HostVideoInputDevice;
|
---|
[48578] | 39 |
|
---|
[48607] | 40 | typedef std::list<ComObjPtr<HostVideoInputDevice> > HostVideoInputDeviceList;
|
---|
[48589] | 41 |
|
---|
[48607] | 42 | class ATL_NO_VTABLE HostVideoInputDevice :
|
---|
| 43 | public HostVideoInputDeviceWrap
|
---|
[48578] | 44 | {
|
---|
| 45 | public:
|
---|
| 46 |
|
---|
[90828] | 47 | DECLARE_COMMON_CLASS_METHODS(HostVideoInputDevice)
|
---|
[48578] | 48 |
|
---|
| 49 | HRESULT FinalConstruct();
|
---|
| 50 | void FinalRelease();
|
---|
| 51 |
|
---|
| 52 | /* Public initializer/uninitializer for internal purposes only. */
|
---|
[48600] | 53 | HRESULT init(const com::Utf8Str &name, const com::Utf8Str &path, const com::Utf8Str &alias);
|
---|
[48578] | 54 | void uninit();
|
---|
| 55 |
|
---|
[49132] | 56 | static HRESULT queryHostDevices(VirtualBox *pVirtualBox, HostVideoInputDeviceList *pList);
|
---|
[48578] | 57 |
|
---|
| 58 | private:
|
---|
| 59 |
|
---|
[48607] | 60 | // wrapped IHostVideoInputDevice properties
|
---|
[48578] | 61 | virtual HRESULT getName(com::Utf8Str &aName) { aName = m.name; return S_OK; }
|
---|
| 62 | virtual HRESULT getPath(com::Utf8Str &aPath) { aPath = m.path; return S_OK; }
|
---|
| 63 | virtual HRESULT getAlias(com::Utf8Str &aAlias) { aAlias = m.alias; return S_OK; }
|
---|
| 64 |
|
---|
| 65 | /* Data. */
|
---|
| 66 | struct Data
|
---|
| 67 | {
|
---|
| 68 | Data()
|
---|
[48955] | 69 | {
|
---|
| 70 | }
|
---|
[48578] | 71 |
|
---|
| 72 | com::Utf8Str name;
|
---|
| 73 | com::Utf8Str path;
|
---|
| 74 | com::Utf8Str alias;
|
---|
| 75 | };
|
---|
| 76 |
|
---|
| 77 | Data m;
|
---|
| 78 | };
|
---|
| 79 |
|
---|
[76562] | 80 | #endif /* !MAIN_INCLUDED_HostVideoInputDeviceImpl_h */
|
---|
[48578] | 81 |
|
---|
| 82 | /* vi: set tabstop=4 shiftwidth=4 expandtab: */
|
---|