backends/drm: only accept xrgb with legacy

xrgb is effectively universally supported, other formats may not be.
In order to make sure things work everywhere, assume only xrgb is supported.
This commit is contained in:
Xaver Hugl 2022-01-25 21:19:27 +01:00
parent 83275c3f31
commit 216d0d6c45
2 changed files with 2 additions and 4 deletions

View file

@ -103,9 +103,8 @@ bool DrmPlane::init()
}
}
if (m_supportedFormats.isEmpty()) {
qCWarning(KWIN_DRM) << "Driver doesn't advertise any formats for this plane. Falling back to XRGB8888 and ARGB8888 without modifiers";
qCWarning(KWIN_DRM) << "Driver doesn't advertise any formats for this plane. Falling back to XRGB8888 without explicit modifiers";
m_supportedFormats.insert(DRM_FORMAT_XRGB8888, {});
m_supportedFormats.insert(DRM_FORMAT_ARGB8888, {});
}
}
return success;

View file

@ -458,8 +458,7 @@ DrmOutput *DrmPipeline::output() const
}
static const QMap<uint32_t, QVector<uint64_t>> legacyFormats = {
{DRM_FORMAT_XRGB8888, {}},
{DRM_FORMAT_ARGB8888, {}}
{DRM_FORMAT_XRGB8888, {}}
};
bool DrmPipeline::isFormatSupported(uint32_t drmFormat) const