KWin
Loading...
Searching...
No Matches
screencast_v1.h
Go to the documentation of this file.
1/*
2 SPDX-FileCopyrightText: 2020 Aleix Pol Gonzalez <aleixpol@kde.org>
3
4 SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL
5*/
6
7#pragma once
8
9#include "kwin_export.h"
10
11#include <QObject>
12#include <memory>
13
14struct wl_resource;
15
16namespace KWin
17{
18class Display;
19class OutputInterface;
20class ScreencastV1InterfacePrivate;
21class ScreencastStreamV1InterfacePrivate;
22class ScreencastStreamV1Interface;
23
24class KWIN_EXPORT ScreencastStreamV1Interface : public QObject
25{
26 Q_OBJECT
27public:
29
30 void sendCreated(quint32 nodeid);
31 void sendFailed(const QString &error);
32 void sendClosed();
33
34Q_SIGNALS:
35 void finished();
36
37private:
39 explicit ScreencastStreamV1Interface(QObject *parent);
40 std::unique_ptr<ScreencastStreamV1InterfacePrivate> d;
41};
42
43class KWIN_EXPORT ScreencastV1Interface : public QObject
44{
45 Q_OBJECT
46
47public:
48 explicit ScreencastV1Interface(Display *display, QObject *parent = nullptr);
50
52 Hidden = 1,
53 Embedded = 2,
54 Metadata = 4,
55 };
56 Q_ENUM(CursorMode)
57
58Q_SIGNALS:
60 void virtualOutputScreencastRequested(ScreencastStreamV1Interface *stream, const QString &name, const QSize &size, double scaling, CursorMode mode);
61 void windowScreencastRequested(ScreencastStreamV1Interface *stream, const QString &winid, CursorMode mode);
62 void regionScreencastRequested(ScreencastStreamV1Interface *stream, const QRect &geometry, qreal scaling, CursorMode mode);
63
64private:
65 std::unique_ptr<ScreencastV1InterfacePrivate> d;
66};
67
68}
Class holding the Wayland server display loop.
Definition display.h:34
void virtualOutputScreencastRequested(ScreencastStreamV1Interface *stream, const QString &name, const QSize &size, double scaling, CursorMode mode)
void outputScreencastRequested(ScreencastStreamV1Interface *stream, OutputInterface *output, CursorMode mode)
void regionScreencastRequested(ScreencastStreamV1Interface *stream, const QRect &geometry, qreal scaling, CursorMode mode)
void windowScreencastRequested(ScreencastStreamV1Interface *stream, const QString &winid, CursorMode mode)
struct _XDisplay Display