MythTV  master
Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
MythWaylandDevice Class Reference

A simple wrapper to retrieve the major Wayland objects from the Qt Wayland native interface. More...

#include <mythwaylandextras.h>

Public Member Functions

 MythWaylandDevice (QWidget *Widget)
 
bool SetOpaqueRegion (QRect Region) const
 Provide a rendering optimisation hint to the compositor. More...
 

Static Public Member Functions

static bool IsAvailable ()
 Check whether we can connect to a Wayland server. More...
 

Public Attributes

wl_display * m_display { nullptr }
 
wl_compositor * m_compositor { nullptr }
 
wl_surface * m_surface { nullptr }
 

Detailed Description

A simple wrapper to retrieve the major Wayland objects from the Qt Wayland native interface.

Note
This class requires access to private Qt headers. When processing the libmythui.pro file, qmake will throw out warnings on binary compatibility
  • our use of the private headers is however limited here, the API has not changed for some time and appears to be stable into Qt6.

Definition at line 27 of file mythwaylandextras.h.

Constructor & Destructor Documentation

◆ MythWaylandDevice()

MythWaylandDevice::MythWaylandDevice ( QWidget *  Widget)
explicit

Definition at line 26 of file mythwaylandextras.cpp.

Member Function Documentation

◆ IsAvailable()

bool MythWaylandDevice::IsAvailable ( )
static

Check whether we can connect to a Wayland server.

Definition at line 100 of file mythwaylandextras.cpp.

◆ SetOpaqueRegion()

bool MythWaylandDevice::SetOpaqueRegion ( QRect  Region) const

Provide a rendering optimisation hint to the compositor.

This is only a hint and support varies by compositor. As a result we still need to use other workarounds to ensure alpha blending works correctly.

See also
MythDisplay::ConfigureQtGUI

Definition at line 54 of file mythwaylandextras.cpp.

Member Data Documentation

◆ m_display

wl_display* MythWaylandDevice::m_display { nullptr }

Definition at line 34 of file mythwaylandextras.h.

Referenced by MythWaylandDevice(), and MythScreenSaverWayland::WindowReady().

◆ m_compositor

wl_compositor* MythWaylandDevice::m_compositor { nullptr }

Definition at line 35 of file mythwaylandextras.h.

Referenced by MythWaylandDevice(), and SetOpaqueRegion().

◆ m_surface

wl_surface* MythWaylandDevice::m_surface { nullptr }

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