Class videocomposer::WaylandDisplay
ClassList > videocomposer > WaylandDisplay
#include <WaylandDisplay.h>
Inherits the following classes: videocomposer::DisplayBackend
Public Functions
| Type | Name |
|---|---|
| WaylandDisplay () |
|
| virtual void | clearCurrent () override |
| virtual void | closeWindow () override |
| virtual void * | getContext () override |
| virtual EGLDisplay | getEGLDisplay () override const |
| virtual PFNEGLCREATEIMAGEKHRPROC | getEglCreateImageKHR () override const |
| virtual PFNEGLDESTROYIMAGEKHRPROC | getEglDestroyImageKHR () override const |
| virtual bool | getFullscreen () override const |
| virtual PFNGLEGLIMAGETARGETTEXTURE2DOESPROC | getGlEGLImageTargetTexture2DOES () override const |
| virtual bool | getOnTop () override const |
| virtual OpenGLRenderer * | getRenderer () override |
| virtual VADisplay | getVADisplay () override const |
| virtual void | getWindowPos (int * x, int * y) override const |
| virtual void | getWindowSize (unsigned int * width, unsigned int * height) override const |
| virtual void | handleEvents () override |
| virtual bool | hasVaapiSupport () override const |
| virtual bool | isWindowOpen () override const |
| virtual void | makeCurrent () override |
| virtual bool | openWindow () override |
| virtual void | render (LayerManager * layerManager, OSDManager * osdManager=nullptr) override |
| virtual void | resize (unsigned int width, unsigned int height) override |
| virtual void | setFullscreen (int action) override |
| virtual void | setOnTop (int action) override |
| virtual void | setPosition (int x, int y) override |
| virtual bool | supportsMultiDisplay () override const |
| virtual void | swapBuffers () override |
| virtual | ~WaylandDisplay () |
Public Functions inherited from videocomposer::DisplayBackend
See videocomposer::DisplayBackend
| Type | Name |
|---|---|
| virtual void | clearCurrent () |
| virtual void | closeWindow () = 0 |
| virtual bool | configureOutputBlend (const std::string & outputName, float left, float right, float top, float bottom, float gamma=2.2f) |
| virtual bool | configureOutputRegion (const std::string & outputName, int canvasX, int canvasY, int canvasWidth=0, int canvasHeight=0) |
| virtual void * | getContext () |
| virtual EGLDisplay | getEGLDisplay () const |
| virtual PFNEGLCREATEIMAGEKHRPROC | getEglCreateImageKHR () const |
| virtual PFNEGLDESTROYIMAGEKHRPROC | getEglDestroyImageKHR () const |
| virtual bool | getFullscreen () const = 0 |
| virtual PFNGLEGLIMAGETARGETTEXSTORAGEEXTPROC | getGlEGLImageTargetTexStorageEXT () const |
| virtual PFNGLEGLIMAGETARGETTEXTURE2DOESPROC | getGlEGLImageTargetTexture2DOES () const |
| virtual bool | getOnTop () const = 0 |
| virtual size_t | getOutputCount () const |
| virtual std::vector< OutputInfo > | getOutputs () const |
| virtual OpenGLRenderer * | getRenderer () |
| virtual VADisplay | getVADisplay () const |
| virtual void | getWindowPos (int * x, int * y) const = 0 |
| virtual void | getWindowSize (unsigned int * width, unsigned int * height) const = 0 |
| virtual void | handleEvents () = 0 |
| virtual bool | hasFatalError () const |
| virtual bool | hasVaapiSupport () const |
| virtual bool | isCaptureEnabled () const |
| virtual bool | isDesktopGL () const |
| virtual bool | isWindowOpen () const = 0 |
| virtual bool | loadConfiguration (const std::string & path="") |
| virtual void | makeCurrent () |
| virtual bool | openWindow () = 0 |
| virtual void | render (LayerManager * layerManager, OSDManager * osdManager=nullptr) = 0 |
| virtual void | resize (unsigned int width, unsigned int height) = 0 |
| virtual bool | saveConfiguration (const std::string & path="") |
| virtual void | setCaptureEnabled (bool enabled, int width=0, int height=0) |
| virtual void | setFullscreen (int action) = 0 |
| virtual void | setOnTop (int action) = 0 |
| virtual bool | setOutputMode (const std::string & outputName, int width, int height, double refresh=0.0) |
| virtual void | setOutputSinkManager (class OutputSinkManager * sinkManager) |
| virtual void | setPosition (int x, int y) = 0 |
| virtual bool | setResolutionMode (const std::string & mode) |
| virtual void | setVideoFramerate (double fps) |
| virtual bool | supportsMultiDisplay () const = 0 |
| virtual void | swapBuffers () |
| virtual | ~DisplayBackend () = default |
Public Static Functions
| Type | Name |
|---|---|
| void | registryHandleGlobal (void * data, struct wl_registry * registry, uint32_t name, const char * interface, uint32_t version) |
| void | registryHandleGlobalRemove (void * data, struct wl_registry * registry, uint32_t name) |
| void | xdgSurfaceConfigure (void * data, struct xdg_surface * xdg_surface, uint32_t serial) |
| void | xdgToplevelClose (void * data, struct xdg_toplevel * xdg_toplevel) |
| void | xdgToplevelConfigure (void * data, struct xdg_toplevel * xdg_toplevel, int32_t width, int32_t height, ::wl_array * states) |
| void | xdgWmBasePing (void * data, struct xdg_wm_base * xdg_wm_base, uint32_t serial) |
Detailed Description
WaylandDisplay - Wayland-based display backend with EGL/OpenGL (Linux only)
Implements DisplayBackend using Wayland + EGL + OpenGL on Linux. Supports VAAPI zero-copy via DMA-BUF import using zwp_linux_dmabuf_v1 protocol.
Note: This backend uses Wayland for windowing and EGL for OpenGL context. For X11 systems, use X11Display instead.
Public Functions Documentation
function WaylandDisplay
videocomposer::WaylandDisplay::WaylandDisplay ()
function clearCurrent
virtual void videocomposer::WaylandDisplay::clearCurrent () override
Clear the current OpenGL context
Implements videocomposer::DisplayBackend::clearCurrent
function closeWindow
virtual void videocomposer::WaylandDisplay::closeWindow () override
Close display window
Implements videocomposer::DisplayBackend::closeWindow
function getContext
virtual void * videocomposer::WaylandDisplay::getContext () override
Get OpenGL context (for OpenGL backends)
Returns:
Pointer to context, or nullptr if not applicable
Implements videocomposer::DisplayBackend::getContext
function getEGLDisplay
inline virtual EGLDisplay videocomposer::WaylandDisplay::getEGLDisplay () override const
Get EGL display (for VAAPI zero-copy interop)
Returns:
EGL display handle, or nullptr if not available
Implements videocomposer::DisplayBackend::getEGLDisplay
function getEglCreateImageKHR
inline virtual PFNEGLCREATEIMAGEKHRPROC videocomposer::WaylandDisplay::getEglCreateImageKHR () override const
Get EGL extension function pointers (for VaapiInterop)
Implements videocomposer::DisplayBackend::getEglCreateImageKHR
function getEglDestroyImageKHR
inline virtual PFNEGLDESTROYIMAGEKHRPROC videocomposer::WaylandDisplay::getEglDestroyImageKHR () override const
Implements videocomposer::DisplayBackend::getEglDestroyImageKHR
function getFullscreen
virtual bool videocomposer::WaylandDisplay::getFullscreen () override const
Get fullscreen state
Returns:
true if fullscreen, false otherwise
Implements videocomposer::DisplayBackend::getFullscreen
function getGlEGLImageTargetTexture2DOES
inline virtual PFNGLEGLIMAGETARGETTEXTURE2DOESPROC videocomposer::WaylandDisplay::getGlEGLImageTargetTexture2DOES () override const
Implements videocomposer::DisplayBackend::getGlEGLImageTargetTexture2DOES
function getOnTop
virtual bool videocomposer::WaylandDisplay::getOnTop () override const
Get always-on-top state
Returns:
true if on top, false otherwise
Implements videocomposer::DisplayBackend::getOnTop
function getRenderer
inline virtual OpenGLRenderer * videocomposer::WaylandDisplay::getRenderer () override
Get the OpenGL renderer
Returns:
Reference to the renderer, or nullptr if not initialized
Implements videocomposer::DisplayBackend::getRenderer
function getVADisplay
inline virtual VADisplay videocomposer::WaylandDisplay::getVADisplay () override const
Get VAAPI display (shared between decoder and EGL interop)
Returns:
VAAPI display handle, or nullptr if not available
Implements videocomposer::DisplayBackend::getVADisplay
function getWindowPos
virtual void videocomposer::WaylandDisplay::getWindowPos (
int * x,
int * y
) override const
Get window position
Parameters:
xOutput X positionyOutput Y position
Implements videocomposer::DisplayBackend::getWindowPos
function getWindowSize
virtual void videocomposer::WaylandDisplay::getWindowSize (
unsigned int * width,
unsigned int * height
) override const
Get window size
Parameters:
widthOutput widthheightOutput height
Implements videocomposer::DisplayBackend::getWindowSize
function handleEvents
virtual void videocomposer::WaylandDisplay::handleEvents () override
Handle window/display events Should be called regularly from main loop
Implements videocomposer::DisplayBackend::handleEvents
function hasVaapiSupport
inline virtual bool videocomposer::WaylandDisplay::hasVaapiSupport () override const
Check if backend supports VAAPI hardware decode
Returns:
true if VAAPI is supported
Implements videocomposer::DisplayBackend::hasVaapiSupport
function isWindowOpen
virtual bool videocomposer::WaylandDisplay::isWindowOpen () override const
Check if window is open
Returns:
true if open, false otherwise
Implements videocomposer::DisplayBackend::isWindowOpen
function makeCurrent
virtual void videocomposer::WaylandDisplay::makeCurrent () override
Make this display's OpenGL context current Required for backends that support OpenGL rendering
Implements videocomposer::DisplayBackend::makeCurrent
function openWindow
virtual bool videocomposer::WaylandDisplay::openWindow () override
Open/create display window
Returns:
true on success, false on failure
Implements videocomposer::DisplayBackend::openWindow
function render
virtual void videocomposer::WaylandDisplay::render (
LayerManager * layerManager,
OSDManager * osdManager=nullptr
) override
Render layers to display
Parameters:
layerManagerLayer manager containing all layers to renderosdManagerOptional OSD manager for on-screen display (can be nullptr)
Implements videocomposer::DisplayBackend::render
function resize
virtual void videocomposer::WaylandDisplay::resize (
unsigned int width,
unsigned int height
) override
Resize window
Parameters:
widthNew widthheightNew height
Implements videocomposer::DisplayBackend::resize
function setFullscreen
virtual void videocomposer::WaylandDisplay::setFullscreen (
int action
) override
Set fullscreen mode
Parameters:
action0=windowed, 1=fullscreen, 2=toggle
Implements videocomposer::DisplayBackend::setFullscreen
function setOnTop
virtual void videocomposer::WaylandDisplay::setOnTop (
int action
) override
Set always-on-top
Parameters:
action0=normal, 1=ontop, 2=toggle
Implements videocomposer::DisplayBackend::setOnTop
function setPosition
virtual void videocomposer::WaylandDisplay::setPosition (
int x,
int y
) override
Set window position
Parameters:
xX positionyY position
Implements videocomposer::DisplayBackend::setPosition
function supportsMultiDisplay
inline virtual bool videocomposer::WaylandDisplay::supportsMultiDisplay () override const
Check if backend supports multi-display
Returns:
true if supported, false otherwise
Implements videocomposer::DisplayBackend::supportsMultiDisplay
function swapBuffers
virtual void videocomposer::WaylandDisplay::swapBuffers () override
Swap/present buffers (for startup splash on X11/Wayland). Default no-op; DRM uses per-surface page flips.
Implements videocomposer::DisplayBackend::swapBuffers
function ~WaylandDisplay
virtual videocomposer::WaylandDisplay::~WaylandDisplay ()
Public Static Functions Documentation
function registryHandleGlobal
static void videocomposer::WaylandDisplay::registryHandleGlobal (
void * data,
struct wl_registry * registry,
uint32_t name,
const char * interface,
uint32_t version
)
function registryHandleGlobalRemove
static void videocomposer::WaylandDisplay::registryHandleGlobalRemove (
void * data,
struct wl_registry * registry,
uint32_t name
)
function xdgSurfaceConfigure
static void videocomposer::WaylandDisplay::xdgSurfaceConfigure (
void * data,
struct xdg_surface * xdg_surface,
uint32_t serial
)
function xdgToplevelClose
static void videocomposer::WaylandDisplay::xdgToplevelClose (
void * data,
struct xdg_toplevel * xdg_toplevel
)
function xdgToplevelConfigure
static void videocomposer::WaylandDisplay::xdgToplevelConfigure (
void * data,
struct xdg_toplevel * xdg_toplevel,
int32_t width,
int32_t height,
::wl_array * states
)
function xdgWmBasePing
static void videocomposer::WaylandDisplay::xdgWmBasePing (
void * data,
struct xdg_wm_base * xdg_wm_base,
uint32_t serial
)
The documentation for this class was generated from the following file src/cuems_videocomposer/cpp/display/WaylandDisplay.h