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
qwaylandeglwindow_p.h
Go to the documentation of this file.
1// Copyright (C) 2016 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//
5// W A R N I N G
6// -------------
7//
8// This file is not part of the Qt API. It exists purely as an
9// implementation detail. This header file may change from version to
10// version without notice, or even be removed.
11//
12// We mean it.
13//
14
15#ifndef QWAYLANDEGLWINDOW_H
16#define QWAYLANDEGLWINDOW_H
17
18#include <QtWaylandClient/private/qwaylandwindow_p.h>
21
22QT_BEGIN_NAMESPACE
23
24class QOpenGLFramebufferObject;
25
26namespace QtWaylandClient {
27
28class QWaylandGLContext;
29
30class Q_WAYLANDCLIENT_EXPORT QWaylandEglWindow : public QWaylandWindow
31{
33public:
37 void ensureSize() override;
38
39 void updateSurface(bool create);
40 QRect contentsRect() const;
41
42 EGLSurface eglSurface() const;
43 GLuint contentFBO() const;
44 GLuint contentTexture() const;
45 bool needToUpdateContentFBO() const { return decoration() && (m_resize || !m_contentFBO); }
46
47 void bindContentFBO();
48
50
52
53private:
55 struct wl_egl_window *m_waylandEglWindow = nullptr;
56
57 // Locks any manipulation of the eglSurface size
60 mutable bool m_resize = false;
61 mutable QOpenGLFramebufferObject *m_contentFBO = nullptr;
62
63 // Size used in the last call to wl_egl_window_resize
65
66 // Size of the buffer used by QWaylandWindow
67 // This is always written to from the main thread, potentially read from the rendering thread
70};
71
72}
73
74QT_END_NAMESPACE
75
76#endif // QWAYLANDEGLWINDOW_H
static const char * qwaylandegl_threadedgl_blacklist_vendor[]
EGLDisplay(* PFNEGLGETPLATFORMDISPLAYEXTPROC)(EGLenum platform, void *native_display, const EGLint *attrib_list)