backends/drm: also force linear layout for dumb buffer cursors

While it usually shouldn't make a difference, it ensures that the buffer import
always works properly

CCBUG: 456306
This commit is contained in:
Xaver Hugl 2022-10-03 21:34:30 +02:00 committed by Vlad Zahorodnii
parent 6ba44deee4
commit 18a72f7187

View file

@ -59,7 +59,7 @@ void EglGbmLayerSurface::destroyResources()
std::optional<OutputLayerBeginFrameInfo> EglGbmLayerSurface::startRendering(const QSize &bufferSize, DrmPlane::Transformations renderOrientation, DrmPlane::Transformations bufferOrientation, const QMap<uint32_t, QVector<uint64_t>> &formats, BufferTarget target)
{
if (!checkGbmSurface(bufferSize, formats, target == BufferTarget::Linear)) {
if (!checkGbmSurface(bufferSize, formats, target == BufferTarget::Linear || target == BufferTarget::Dumb)) {
return std::nullopt;
}
if (!m_gbmSurface->makeContextCurrent()) {