Qt 6.x
The Qt SDK
Loading...
Searching...
No Matches
qkmsdevice.cpp File Reference
#include "qkmsdevice_p.h"
#include <QtCore/QJsonDocument>
#include <QtCore/QJsonObject>
#include <QtCore/QJsonArray>
#include <QtCore/QFile>
#include <QtCore/QLoggingCategory>
#include <errno.h>
+ Include dependency graph for qkmsdevice.cpp:

Go to the source code of this file.

Classes

struct  OrderedScreen
 

Macros

#define ARRAY_LENGTH(a)   (sizeof (a) / sizeof (a)[0])
 

Enumerations

enum  OutputConfiguration {
  OutputConfigOff , OutputConfigPreferred , OutputConfigCurrent , OutputConfigSkip ,
  OutputConfigMode , OutputConfigModeline
}
 

Functions

static QByteArray nameForConnector (const drmModeConnectorPtr connector)
 
static bool parseModeline (const QByteArray &text, drmModeModeInfoPtr mode)
 
static void assignPlane (QKmsOutput *output, QKmsPlane *plane)
 
QDebug operator<< (QDebug dbg, const OrderedScreen &s)
 
static bool orderedScreenLessThan (const OrderedScreen &a, const OrderedScreen &b)
 
static bool propTypeIs (drmModePropertyPtr prop, uint32_t type)
 

Variables

static const char *const connector_type_names []
 

Macro Definition Documentation

◆ ARRAY_LENGTH

#define ARRAY_LENGTH (   a)    (sizeof (a) / sizeof (a)[0])

Definition at line 16 of file qkmsdevice.cpp.

Enumeration Type Documentation

◆ OutputConfiguration

Enumerator
OutputConfigOff 
OutputConfigPreferred 
OutputConfigCurrent 
OutputConfigSkip 
OutputConfigMode 
OutputConfigModeline 

Definition at line 24 of file qkmsdevice.cpp.

Function Documentation

◆ assignPlane()

static void assignPlane ( QKmsOutput output,
QKmsPlane plane 
)
inlinestatic

Definition at line 145 of file qkmsdevice.cpp.

References QKmsPlane::activeCrtcId, and output.

Referenced by QKmsDevice::createScreenForConnector().

+ Here is the caller graph for this function:

◆ nameForConnector()

static QByteArray nameForConnector ( const drmModeConnectorPtr  connector)
static

Definition at line 90 of file qkmsdevice.cpp.

References ARRAY_LENGTH, connector_type_names, and QByteArray::number().

Referenced by QKmsDevice::createScreenForConnector().

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

◆ operator<<()

QDebug operator<< ( QDebug  dbg,
const OrderedScreen s 
)

Definition at line 578 of file qkmsdevice.cpp.

◆ orderedScreenLessThan()

static bool orderedScreenLessThan ( const OrderedScreen a,
const OrderedScreen b 
)
static

Definition at line 589 of file qkmsdevice.cpp.

Referenced by QKmsDevice::createScreens().

+ Here is the caller graph for this function:

◆ parseModeline()

static bool parseModeline ( const QByteArray text,
drmModeModeInfoPtr  mode 
)
static

Definition at line 102 of file qkmsdevice.cpp.

References QString::constData(), and text.

Referenced by QKmsDevice::createScreenForConnector().

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

◆ propTypeIs()

static bool propTypeIs ( drmModePropertyPtr  prop,
uint32_t  type 
)
inlinestatic

Definition at line 752 of file qkmsdevice.cpp.

References DRM_MODE_PROP_EXTENDED_TYPE.

Referenced by QKmsDevice::discoverPlanes(), and QKmsDevice::enumerateProperties().

+ Here is the caller graph for this function:

Variable Documentation

◆ connector_type_names

const char* const connector_type_names[]
static
Initial value:
= {
"None",
"VGA",
"DVI",
"DVI",
"DVI",
"Composite",
"TV",
"LVDS",
"CTV",
"DIN",
"DP",
"HDMI",
"HDMI",
"TV",
"eDP",
"Virtual",
"DSI"
}

Definition at line 70 of file qkmsdevice.cpp.

Referenced by nameForConnector().