MythTV
master
|
#include <libmythui/platforms/mythdrmdevice.h>
Public Member Functions | |
~MythDRMDevice () | |
bool | Authenticated () const |
bool | Atomic () const |
int | GetFD () const |
QString | GetSerialNumber () const |
QScreen * | GetScreen () const |
QSize | GetResolution () const |
QSize | GetPhysicalSize () const |
double | GetRefreshRate () const |
Return the refresh rate we think is in use. More... | |
MythEDID | GetEDID () const |
DRMCrtc | GetCrtc () const |
DRMConn | GetConnector () const |
const DRMModes & | GetModes () const |
bool | CanSwitchModes () const |
bool | SwitchMode (int ModeIndex) |
Set the required video mode. More... | |
Static Public Member Functions | |
static std::tuple< QString, QStringList > | GetDeviceList () |
static MythDRMPtr | Create (QScreen *qScreen, const QString &Device=QString(), bool NeedPlanes=true) |
Create a MythDRMDevice instance. More... | |
Protected Member Functions | |
MythDRMDevice (QScreen *qScreen, const QString &Device=QString()) | |
Constructor used when we have no DRM handles from Qt. More... | |
Private Member Functions | |
bool | Open () |
void | Authenticate () |
Attempt to acquire privileged DRM access. More... | |
void | Load () |
bool | Initialise () |
QString | FindBestDevice () |
Static Private Member Functions | |
static bool | ConfirmDevice (const QString &Device) |
Private Attributes | |
bool | m_valid { false } |
QScreen * | m_screen { nullptr } |
QString | m_deviceName |
bool | m_openedDevice { true } |
int | m_fd { -1 } |
bool | m_atomic { false } |
bool | m_authenticated { false } |
DRMConns | m_connectors |
DRMEncs | m_encoders |
DRMCrtcs | m_crtcs |
DRMPlanes | m_planes |
DRMConn | m_connector { nullptr } |
DRMCrtc | m_crtc { nullptr } |
QSize | m_resolution |
QSize | m_physicalSize |
double | m_refreshRate { 0.0 } |
double | m_adjustedRefreshRate { 0.0 } |
QString | m_serialNumber |
LogLevel_t | m_verbose { LOG_INFO } |
MythEDID | m_edid |
Definition at line 24 of file mythdrmdevice.h.
MythDRMDevice::~MythDRMDevice | ( | ) |
Definition at line 555 of file mythdrmdevice.cpp.
|
explicitprotected |
Constructor used when we have no DRM handles from Qt.
This will construct an instance with little functionality as it will not be authenticated. Useful for confirming current display settings and little else.
Definition at line 391 of file mythdrmdevice.cpp.
Referenced by Create().
|
static |
Definition at line 371 of file mythdrmdevice.cpp.
Referenced by FindBestDevice().
|
static |
Create a MythDRMDevice instance.
Definition at line 316 of file mythdrmdevice.cpp.
Referenced by MythVRR::Create(), MythDisplayDRM::MythDisplayDRM(), and MythDisplayDRM::ScreenChanged().
bool MythDRMDevice::Authenticated | ( | ) | const |
Definition at line 574 of file mythdrmdevice.cpp.
bool MythDRMDevice::Atomic | ( | ) | const |
Definition at line 579 of file mythdrmdevice.cpp.
int MythDRMDevice::GetFD | ( | ) | const |
Definition at line 584 of file mythdrmdevice.cpp.
QString MythDRMDevice::GetSerialNumber | ( | ) | const |
Definition at line 589 of file mythdrmdevice.cpp.
Referenced by FindBestDevice().
QScreen * MythDRMDevice::GetScreen | ( | ) | const |
Definition at line 594 of file mythdrmdevice.cpp.
QSize MythDRMDevice::GetResolution | ( | ) | const |
Definition at line 599 of file mythdrmdevice.cpp.
QSize MythDRMDevice::GetPhysicalSize | ( | ) | const |
Definition at line 604 of file mythdrmdevice.cpp.
double MythDRMDevice::GetRefreshRate | ( | ) | const |
Return the refresh rate we think is in use.
Definition at line 624 of file mythdrmdevice.cpp.
MythEDID MythDRMDevice::GetEDID | ( | ) | const |
Definition at line 609 of file mythdrmdevice.cpp.
DRMCrtc MythDRMDevice::GetCrtc | ( | ) | const |
Definition at line 872 of file mythdrmdevice.cpp.
DRMConn MythDRMDevice::GetConnector | ( | ) | const |
Definition at line 877 of file mythdrmdevice.cpp.
const DRMModes & MythDRMDevice::GetModes | ( | ) | const |
Definition at line 637 of file mythdrmdevice.cpp.
bool MythDRMDevice::CanSwitchModes | ( | ) | const |
Definition at line 631 of file mythdrmdevice.cpp.
bool MythDRMDevice::SwitchMode | ( | int | ModeIndex | ) |
Set the required video mode.
Definition at line 651 of file mythdrmdevice.cpp.
|
private |
Definition at line 564 of file mythdrmdevice.cpp.
Referenced by MythDRMDevice().
|
private |
Attempt to acquire privileged DRM access.
This function is probably pointless. If we have retrieved a file descriptor from the Qt platform plugin then we are authenticated and if we have not, authentication will always fail (as either X, Wayland or Qt have master privileges)
Definition at line 692 of file mythdrmdevice.cpp.
Referenced by MythDRMDevice().
|
private |
Definition at line 717 of file mythdrmdevice.cpp.
Referenced by Initialise().
|
private |
Definition at line 724 of file mythdrmdevice.cpp.
Referenced by MythDRMDevice().
|
private |
Definition at line 820 of file mythdrmdevice.cpp.
Referenced by Open().
|
staticprivate |
Definition at line 856 of file mythdrmdevice.cpp.
Referenced by FindBestDevice().
Definition at line 83 of file mythdrmdevice.h.
Referenced by Authenticated(), CanSwitchModes(), and MythDRMDevice().
|
private |
Definition at line 84 of file mythdrmdevice.h.
Referenced by FindBestDevice(), GetScreen(), and Initialise().
|
private |
Definition at line 85 of file mythdrmdevice.h.
Referenced by MythDRMDevice(), and Open().
Definition at line 86 of file mythdrmdevice.h.
Referenced by ~MythDRMDevice().
|
private |
Definition at line 87 of file mythdrmdevice.h.
Referenced by Authenticate(), GetFD(), Initialise(), Load(), Open(), SwitchMode(), and ~MythDRMDevice().
Definition at line 88 of file mythdrmdevice.h.
Referenced by Atomic(), Authenticate(), CanSwitchModes(), and SwitchMode().
Definition at line 89 of file mythdrmdevice.h.
Referenced by Authenticate(), Authenticated(), CanSwitchModes(), GetModes(), and SwitchMode().
|
private |
Definition at line 90 of file mythdrmdevice.h.
Referenced by Initialise(), and Load().
|
private |
Definition at line 91 of file mythdrmdevice.h.
Referenced by Initialise(), and Load().
|
private |
Definition at line 92 of file mythdrmdevice.h.
Referenced by Initialise(), and Load().
|
private |
Definition at line 93 of file mythdrmdevice.h.
|
private |
Definition at line 94 of file mythdrmdevice.h.
Referenced by GetConnector(), GetModes(), Initialise(), and SwitchMode().
|
private |
Definition at line 95 of file mythdrmdevice.h.
Referenced by GetCrtc(), Initialise(), and SwitchMode().
|
private |
Definition at line 96 of file mythdrmdevice.h.
Referenced by GetResolution(), and Initialise().
|
private |
Definition at line 97 of file mythdrmdevice.h.
Referenced by GetPhysicalSize(), and Initialise().
|
private |
Definition at line 98 of file mythdrmdevice.h.
Referenced by GetRefreshRate(), and Initialise().
|
private |
Definition at line 99 of file mythdrmdevice.h.
Referenced by GetRefreshRate(), and SwitchMode().
|
private |
Definition at line 100 of file mythdrmdevice.h.
Referenced by GetSerialNumber(), and Initialise().
|
private |
Definition at line 101 of file mythdrmdevice.h.
Referenced by Authenticate(), FindBestDevice(), Initialise(), MythDRMDevice(), and ~MythDRMDevice().
|
private |
Definition at line 102 of file mythdrmdevice.h.
Referenced by GetEDID(), and Initialise().