diff options
author | Elvis Lee <kwangwoong.lee@lge.com> | 2020-12-31 10:53:08 +0900 |
---|---|---|
committer | Elvis Lee <kwangwoong.lee@lge.com> | 2021-04-29 07:38:17 +0900 |
commit | cd72f971739ab27e4a613baf560f0482388ade20 (patch) | |
tree | 0513413864dd3a2dcb3a0239f1cf607e14a4c5a9 /src/hardwareintegration | |
parent | 723dd936bb6b1055c4a552366cb7c220390d68d2 (diff) | |
download | qtwayland-cd72f971739ab27e4a613baf560f0482388ade20.tar.gz |
Export wayland-egl compositor hwintegration
Support wayland-egl compositor hwintegration
as a module for external build
Change-Id: I794ad4eb38fc2dda31ace1b0eeb2e001020d0956
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
Diffstat (limited to 'src/hardwareintegration')
-rw-r--r-- | src/hardwareintegration/CMakeLists.txt | 3 | ||||
-rw-r--r-- | src/hardwareintegration/compositor/CMakeLists.txt | 5 | ||||
-rw-r--r-- | src/hardwareintegration/compositor/wayland-egl/CMakeLists.txt | 21 | ||||
-rw-r--r-- | src/hardwareintegration/compositor/wayland-egl/wayland-egl.pri | 2 | ||||
-rw-r--r-- | src/hardwareintegration/compositor/wayland-egl/waylandeglclientbufferintegration.cpp | 2 | ||||
-rw-r--r-- | src/hardwareintegration/compositor/wayland-egl/waylandeglclientbufferintegration_p.h (renamed from src/hardwareintegration/compositor/wayland-egl/waylandeglclientbufferintegration.h) | 7 |
6 files changed, 34 insertions, 6 deletions
diff --git a/src/hardwareintegration/CMakeLists.txt b/src/hardwareintegration/CMakeLists.txt index 599de861..f2bab1e1 100644 --- a/src/hardwareintegration/CMakeLists.txt +++ b/src/hardwareintegration/CMakeLists.txt @@ -1,3 +1,6 @@ if(TARGET Qt::WaylandClient) add_subdirectory(client) endif() +if(TARGET Qt::WaylandCompositor) + add_subdirectory(compositor) +endif() diff --git a/src/hardwareintegration/compositor/CMakeLists.txt b/src/hardwareintegration/compositor/CMakeLists.txt new file mode 100644 index 00000000..82e0be9d --- /dev/null +++ b/src/hardwareintegration/compositor/CMakeLists.txt @@ -0,0 +1,5 @@ +# Generated from compositor.pro. + +if(QT_FEATURE_wayland_egl) + add_subdirectory(wayland-egl) +endif() diff --git a/src/hardwareintegration/compositor/wayland-egl/CMakeLists.txt b/src/hardwareintegration/compositor/wayland-egl/CMakeLists.txt new file mode 100644 index 00000000..0858d492 --- /dev/null +++ b/src/hardwareintegration/compositor/wayland-egl/CMakeLists.txt @@ -0,0 +1,21 @@ +##################################################################### +## WaylandEglCompositorHwIntegration Module: +##################################################################### +qt_find_package(EGL) # special case + +qt_internal_add_module(WaylandEglCompositorHwIntegration + CONFIG_MODULE_NAME wayland_egl_compositor_hw_integration + INTERNAL_MODULE + SOURCES + waylandeglclientbufferintegration.cpp waylandeglclientbufferintegration_p.h + INCLUDE_DIRECTORIES + ${CMAKE_CURRENT_SOURCE_DIR} + LIBRARIES + EGL::EGL + Wayland::Egl + Wayland::Server + PUBLIC_LIBRARIES + Qt::Core + Qt::Gui + Qt::WaylandCompositorPrivate +) diff --git a/src/hardwareintegration/compositor/wayland-egl/wayland-egl.pri b/src/hardwareintegration/compositor/wayland-egl/wayland-egl.pri index 0a90583b..23615f31 100644 --- a/src/hardwareintegration/compositor/wayland-egl/wayland-egl.pri +++ b/src/hardwareintegration/compositor/wayland-egl/wayland-egl.pri @@ -6,4 +6,4 @@ SOURCES += \ $$PWD/waylandeglclientbufferintegration.cpp HEADERS += \ - $$PWD/waylandeglclientbufferintegration.h + $$PWD/waylandeglclientbufferintegration_p.h diff --git a/src/hardwareintegration/compositor/wayland-egl/waylandeglclientbufferintegration.cpp b/src/hardwareintegration/compositor/wayland-egl/waylandeglclientbufferintegration.cpp index 8649e70b..5d53b615 100644 --- a/src/hardwareintegration/compositor/wayland-egl/waylandeglclientbufferintegration.cpp +++ b/src/hardwareintegration/compositor/wayland-egl/waylandeglclientbufferintegration.cpp @@ -27,7 +27,7 @@ ** ****************************************************************************/ -#include "waylandeglclientbufferintegration.h" +#include "waylandeglclientbufferintegration_p.h" #include <QtWaylandCompositor/QWaylandCompositor> #include <qpa/qplatformnativeinterface.h> diff --git a/src/hardwareintegration/compositor/wayland-egl/waylandeglclientbufferintegration.h b/src/hardwareintegration/compositor/wayland-egl/waylandeglclientbufferintegration_p.h index 7bd13466..986678f3 100644 --- a/src/hardwareintegration/compositor/wayland-egl/waylandeglclientbufferintegration.h +++ b/src/hardwareintegration/compositor/wayland-egl/waylandeglclientbufferintegration_p.h @@ -38,7 +38,7 @@ QT_BEGIN_NAMESPACE class WaylandEglClientBufferIntegrationPrivate; -class WaylandEglClientBufferIntegration : public QtWayland::ClientBufferIntegration +class Q_WAYLAND_COMPOSITOR_EXPORT WaylandEglClientBufferIntegration : public QtWayland::ClientBufferIntegration { Q_DECLARE_PRIVATE(WaylandEglClientBufferIntegration) public: @@ -56,9 +56,10 @@ private: struct BufferState; -class WaylandEglClientBuffer : public QtWayland::ClientBuffer +class Q_WAYLAND_COMPOSITOR_EXPORT WaylandEglClientBuffer : public QtWayland::ClientBuffer { public: + WaylandEglClientBuffer(WaylandEglClientBufferIntegration* integration, wl_resource *bufferResource); ~WaylandEglClientBuffer() override; QWaylandBufferRef::BufferFormatEgl bufferFormatEgl() const override; @@ -74,8 +75,6 @@ private: friend class WaylandEglClientBufferIntegration; friend class WaylandEglClientBufferIntegrationPrivate; - WaylandEglClientBuffer(WaylandEglClientBufferIntegration* integration, wl_resource *bufferResource); - BufferState *d = nullptr; WaylandEglClientBufferIntegration *m_integration = nullptr; }; |