2#include "libmythbase/mythconfig.h"
20#define LOC QString("VRR: ")
48 : m_controllable(Controllable),
51 m_range(
std::move(Range))
64#if CONFIG_X11 || CONFIG_DRM
96 LOG(VB_GENERAL, LOG_INFO,
LOC +
"No variable refresh rate support detected");
100 LOG(VB_GENERAL, LOG_INFO,
LOC + QString(
"VRR type '%1': Enabled: %2 Controllable: %3 %4")
101 .arg(result->TypeToString()).arg(result->Enabled()).arg(result->IsControllable())
102 .arg(result->RangeDescription()));
126 case FreeSync:
return QObject::tr(
"FreeSync");
127 case GSync:
return QObject::tr(
"GSync");
128 case GSyncCompat:
return QObject::tr(
"GSync Compatible");
131 return QObject::tr(
"None");
138 return QObject::tr(
"Range: %1-%2%3")
140 .arg(std::get<2>(
m_range) ?
"" :
" (Estimated)");
static MythDRMPtr Create(QScreen *qScreen, const QString &Device=QString(), bool NeedPlanes=true)
Create a MythDRMDevice instance.
static MythVRRPtr CreateFreeSync(const MythDRMPtr &Device, MythVRRRange Range)
QScreen * GetCurrentScreen()
Return a pointer to the screen to use.
MythVRRRange GetVRRRange() const
Return the range of supported refresh rates.
static MythVRRPtr CreateGSync(const NVControl &Device, MythVRRRange Range)
static NVControl Create()
Create a valid instance of MythNVControl.
MythVRR(bool Controllable, VRRType Type, bool Enabled, MythVRRRange Range)
MythVRRRange GetRange() const
static MythVRRPtr Create(class MythDisplay *MDisplay)
Create a concrete implementation of MythVRR suitable for the given Display.
QString RangeDescription() const
QString TypeToString() const
bool IsControllable() const
static constexpr const char * DRM_QUIET
std::tuple< int, int, bool > MythVRRRange
#define LOG(_MASK_, _LEVEL_, _QSTRING_)
std::shared_ptr< class MythVRR > MythVRRPtr