Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
qpipewire_camera_p.h
Go to the documentation of this file.
1// Copyright (C) 2026 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3
4#ifndef QPIPEWIRE_CAMERA_P_H
5#define QPIPEWIRE_CAMERA_P_H
6
7//
8// W A R N I N G
9// -------------
10//
11// This file is not part of the Qt API. It exists purely as an
12// implementation detail. This header file may change from version to
13// version without notice, or even be removed.
14//
15// We mean it.
16//
17
18#include <QtMultimedia/private/qplatformcamera_p.h>
19#include <QtMultimedia/private/qtmultimediaglobal_p.h>
20#include <QtMultimedia/qcameradevice.h>
21
22#include <chrono>
23#include <memory>
24#include <optional>
25
26QT_BEGIN_NAMESPACE
27
28namespace QtPipeWire {
29
30class QPipeWireVideoStream;
31
32class Q_MULTIMEDIA_EXPORT QPipeWireCamera : public QPlatformCamera
33{
35
36public:
39
40 bool isActive() const override;
41 void setActive(bool active) override;
42
45
47
48private:
49 bool startStream();
50 void stopStream();
51
52 // Returns true if the resolved format changed.
54
55 bool m_active = false;
58 // Written on the PipeWire thread; read only after stopStream() has synchronized with it.
60};
61
62} // namespace QtPipeWire
63
64QT_END_NAMESPACE
65
66#endif // QPIPEWIRE_CAMERA_P_H
Combined button and popup list for selecting options.
Q_STATIC_LOGGING_CATEGORY(lcPipewireAudioSink, "qt.multimedia.pipewire.audiosink")