Qt 6.x
The Qt SDK
Loading...
Searching...
No Matches
WaylandEglClientBufferIntegrationPrivate Class Reference
+ Collaboration diagram for WaylandEglClientBufferIntegrationPrivate:

Public Member Functions

 WaylandEglClientBufferIntegrationPrivate ()
 
void initBuffer (WaylandEglClientBuffer *buffer)
 
void initEglTexture (WaylandEglClientBuffer *buffer, EGLint format)
 
bool ensureContext ()
 
bool initEglStream (WaylandEglClientBuffer *buffer, struct ::wl_resource *bufferHandle)
 
void setupBufferAndCleanup (BufferState *bs, QOpenGLTexture *texture, int plane)
 
void handleEglstreamTexture (WaylandEglClientBuffer *buffer, wl_resource *bufferHandle)
 
void registerBuffer (struct ::wl_resource *buffer, BufferState state)
 
void deleteGLTextureWhenPossible (QOpenGLTexture *texture, QOpenGLContext *ctx)
 
void deleteOrphanedTextures ()
 
void deleteSpecificOrphanedTexture (QOpenGLTexture *texture)
 

Static Public Member Functions

static WaylandEglClientBufferIntegrationPrivateget (WaylandEglClientBufferIntegration *integration)
 

Public Attributes

EGLDisplay egl_display = EGL_NO_DISPLAY
 
bool display_bound = false
 
::wl_display * wlDisplay = nullptr
 
QOffscreenSurfaceoffscreenSurface = nullptr
 
QOpenGLContextlocalContext = nullptr
 
QMutex orphanedTexturesLock
 
QList< QOpenGLTexture * > orphanedTextures
 
QList< QMetaObject::ConnectionorphanedTexturesAboutToBeDestroyedConnection
 
PFNEGLBINDWAYLANDDISPLAYWL egl_bind_wayland_display = nullptr
 
PFNEGLUNBINDWAYLANDDISPLAYWL egl_unbind_wayland_display = nullptr
 
PFNEGLQUERYWAYLANDBUFFERWL_compat egl_query_wayland_buffer = nullptr
 
PFNEGLCREATEIMAGEKHRPROC egl_create_image = nullptr
 
PFNEGLDESTROYIMAGEKHRPROC egl_destroy_image = nullptr
 
PFNGLEGLIMAGETARGETTEXTURE2DOESPROC gl_egl_image_target_texture_2d = nullptr
 
QEGLStreamConveniencefuncs = nullptr
 

Static Public Attributes

static bool shuttingDown = false
 

Detailed Description

Definition at line 141 of file waylandeglclientbufferintegration.cpp.

Constructor & Destructor Documentation

◆ WaylandEglClientBufferIntegrationPrivate()

WaylandEglClientBufferIntegrationPrivate::WaylandEglClientBufferIntegrationPrivate ( )

Definition at line 187 of file waylandeglclientbufferintegration.cpp.

Member Function Documentation

◆ deleteGLTextureWhenPossible()

void WaylandEglClientBufferIntegrationPrivate::deleteGLTextureWhenPossible ( QOpenGLTexture texture,
QOpenGLContext ctx 
)

Definition at line 420 of file waylandeglclientbufferintegration.cpp.

References QOpenGLContext::aboutToBeDestroyed(), QObject::connect(), deleteSpecificOrphanedTexture(), Qt::DirectConnection, orphanedTextures, orphanedTexturesAboutToBeDestroyedConnection, orphanedTexturesLock, Q_ASSERT, Q_FUNC_INFO, qCDebug, and QList< T >::size().

+ Here is the call graph for this function:

◆ deleteOrphanedTextures()

void WaylandEglClientBufferIntegrationPrivate::deleteOrphanedTextures ( )

Definition at line 437 of file waylandeglclientbufferintegration.cpp.

References QList< T >::clear(), con, QOpenGLContext::currentContext(), QObject::disconnect(), i, orphanedTextures, orphanedTexturesAboutToBeDestroyedConnection, orphanedTexturesLock, Q_ASSERT, Q_FUNC_INFO, qCDebug, qDeleteAll(), and QList< T >::size().

+ Here is the call graph for this function:

◆ deleteSpecificOrphanedTexture()

void WaylandEglClientBufferIntegrationPrivate::deleteSpecificOrphanedTexture ( QOpenGLTexture texture)

Definition at line 458 of file waylandeglclientbufferintegration.cpp.

References con, QObject::disconnect(), i, QListSpecialMethodsBase< T >::indexOf(), QList< T >::length(), orphanedTextures, orphanedTexturesAboutToBeDestroyedConnection, orphanedTexturesLock, Q_ASSERT, Q_FUNC_INFO, qCDebug, qCWarning, QList< T >::removeAt(), QList< T >::size(), and QList< T >::takeAt().

Referenced by deleteGLTextureWhenPossible().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ ensureContext()

bool WaylandEglClientBufferIntegrationPrivate::ensureContext ( )

Definition at line 273 of file waylandeglclientbufferintegration.cpp.

References QOffscreenSurface::create(), QOpenGLContext::create(), QOpenGLContext::currentContext(), QOpenGLContext::format(), QOpenGLContext::globalShareContext(), localContext, QOpenGLContext::makeCurrent(), offscreenSurface, QOffscreenSurface::setFormat(), and QOpenGLContext::setShareContext().

Referenced by handleEglstreamTexture().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ get()

static WaylandEglClientBufferIntegrationPrivate * WaylandEglClientBufferIntegrationPrivate::get ( WaylandEglClientBufferIntegration integration)
inlinestatic

Definition at line 178 of file waylandeglclientbufferintegration.cpp.

References QScopedPointer< T, Cleanup >::data(), nullptr, and shuttingDown.

Referenced by WaylandEglClientBuffer::WaylandEglClientBuffer(), WaylandEglClientBuffer::~WaylandEglClientBuffer(), WaylandEglClientBuffer::lockNativeBuffer(), WaylandEglClientBuffer::setCommitted(), WaylandEglClientBuffer::toOpenGlTexture(), and WaylandEglClientBuffer::unlockNativeBuffer().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ handleEglstreamTexture()

void WaylandEglClientBufferIntegrationPrivate::handleEglstreamTexture ( WaylandEglClientBuffer buffer,
wl_resource *  bufferHandle 
)

◆ initBuffer()

void WaylandEglClientBufferIntegrationPrivate::initBuffer ( WaylandEglClientBuffer buffer)

Definition at line 191 of file waylandeglclientbufferintegration.cpp.

References egl_display, egl_query_wayland_buffer, and initEglTexture().

+ Here is the call graph for this function:

◆ initEglStream()

bool WaylandEglClientBufferIntegrationPrivate::initEglStream ( WaylandEglClientBuffer buffer,
struct ::wl_resource *  bufferHandle 
)

Definition at line 339 of file waylandeglclientbufferintegration.cpp.

References QEGLStreamConvenience::create_stream_attrib_nv, QEGLStreamConvenience::create_stream_from_file_descriptor, QOpenGLContext::currentContext(), QEGLStreamConvenience::destroy_stream, egl_display, egl_error_string(), EGL_NO_FILE_DESCRIPTOR_KHR, EGL_NO_STREAM_KHR, egl_query_wayland_buffer, EGL_TEXTURE_EXTERNAL_WL, EGL_WAYLAND_BUFFER_WL, EGL_WAYLAND_EGLSTREAM_WL, funcs, GL_TEXTURE_EXTERNAL_OES, Qt::hex(), BufferState::ModeEGLStream, Q_FUNC_INFO, qCDebug, qCWarning, setupBufferAndCleanup(), state, and QEGLStreamConvenience::stream_consumer_gltexture.

Referenced by handleEglstreamTexture().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ initEglTexture()

void WaylandEglClientBufferIntegrationPrivate::initEglTexture ( WaylandEglClientBuffer buffer,
EGLint  format 
)

Definition at line 199 of file waylandeglclientbufferintegration.cpp.

References egl_create_image, egl_display, egl_query_wayland_buffer, EGL_TEXTURE_EXTERNAL_WL, EGL_TEXTURE_RGB, EGL_TEXTURE_RGBA, EGL_TEXTURE_Y_U_V_WL, EGL_TEXTURE_Y_UV_WL, EGL_TEXTURE_Y_XUXV_WL, EGL_WAYLAND_BUFFER_WL, EGL_WAYLAND_PLANE_WL, EGL_WAYLAND_Y_INVERTED_WL, EGLBoolean(), gl_egl_image_target_texture_2d, i, BufferState::ModeEGLImage, qCWarning, ret, and state.

Referenced by initBuffer().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ registerBuffer()

void WaylandEglClientBufferIntegrationPrivate::registerBuffer ( struct ::wl_resource *  buffer,
BufferState  state 
)

◆ setupBufferAndCleanup()

void WaylandEglClientBufferIntegrationPrivate::setupBufferAndCleanup ( BufferState bs,
QOpenGLTexture texture,
int  plane 
)

Definition at line 296 of file waylandeglclientbufferintegration.cpp.

References QOpenGLContext::aboutToBeDestroyed(), QObject::connect(), QOpenGLContext::currentContext(), Qt::DirectConnection, Q_ASSERT, Q_FUNC_INFO, qCDebug, BufferState::textures, BufferState::texturesAboutToBeDestroyedConnection, BufferState::texturesContext, and BufferState::texturesLock.

Referenced by initEglStream().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Member Data Documentation

◆ display_bound

bool WaylandEglClientBufferIntegrationPrivate::display_bound = false

Definition at line 158 of file waylandeglclientbufferintegration.cpp.

◆ egl_bind_wayland_display

PFNEGLBINDWAYLANDDISPLAYWL WaylandEglClientBufferIntegrationPrivate::egl_bind_wayland_display = nullptr

Definition at line 168 of file waylandeglclientbufferintegration.cpp.

◆ egl_create_image

PFNEGLCREATEIMAGEKHRPROC WaylandEglClientBufferIntegrationPrivate::egl_create_image = nullptr

Definition at line 172 of file waylandeglclientbufferintegration.cpp.

Referenced by initEglTexture().

◆ egl_destroy_image

PFNEGLDESTROYIMAGEKHRPROC WaylandEglClientBufferIntegrationPrivate::egl_destroy_image = nullptr

Definition at line 173 of file waylandeglclientbufferintegration.cpp.

◆ egl_display

EGLDisplay WaylandEglClientBufferIntegrationPrivate::egl_display = EGL_NO_DISPLAY

◆ egl_query_wayland_buffer

PFNEGLQUERYWAYLANDBUFFERWL_compat WaylandEglClientBufferIntegrationPrivate::egl_query_wayland_buffer = nullptr

◆ egl_unbind_wayland_display

PFNEGLUNBINDWAYLANDDISPLAYWL WaylandEglClientBufferIntegrationPrivate::egl_unbind_wayland_display = nullptr

Definition at line 169 of file waylandeglclientbufferintegration.cpp.

◆ funcs

QEGLStreamConvenience* WaylandEglClientBufferIntegrationPrivate::funcs = nullptr

Definition at line 177 of file waylandeglclientbufferintegration.cpp.

Referenced by handleEglstreamTexture(), and initEglStream().

◆ gl_egl_image_target_texture_2d

PFNGLEGLIMAGETARGETTEXTURE2DOESPROC WaylandEglClientBufferIntegrationPrivate::gl_egl_image_target_texture_2d = nullptr

Definition at line 175 of file waylandeglclientbufferintegration.cpp.

Referenced by initEglTexture().

◆ localContext

QOpenGLContext* WaylandEglClientBufferIntegrationPrivate::localContext = nullptr

Definition at line 161 of file waylandeglclientbufferintegration.cpp.

Referenced by ensureContext(), and handleEglstreamTexture().

◆ offscreenSurface

QOffscreenSurface* WaylandEglClientBufferIntegrationPrivate::offscreenSurface = nullptr

Definition at line 160 of file waylandeglclientbufferintegration.cpp.

Referenced by ensureContext().

◆ orphanedTextures

QList<QOpenGLTexture *> WaylandEglClientBufferIntegrationPrivate::orphanedTextures

◆ orphanedTexturesAboutToBeDestroyedConnection

QList<QMetaObject::Connection> WaylandEglClientBufferIntegrationPrivate::orphanedTexturesAboutToBeDestroyedConnection

◆ orphanedTexturesLock

QMutex WaylandEglClientBufferIntegrationPrivate::orphanedTexturesLock

◆ shuttingDown

bool WaylandEglClientBufferIntegrationPrivate::shuttingDown = false
static

◆ wlDisplay

::wl_display* WaylandEglClientBufferIntegrationPrivate::wlDisplay = nullptr

Definition at line 159 of file waylandeglclientbufferintegration.cpp.


The documentation for this class was generated from the following file: