opengl: fix swapped rgb drm formats

This commit is contained in:
Vaxry 2023-12-01 17:23:50 +00:00
parent 9c09f2a847
commit 6e8b9ef7d8

View file

@ -2070,9 +2070,9 @@ uint32_t CHyprOpenGLImpl::getPreferredReadFormat(CMonitor* pMonitor) {
return DRM_FORMAT_XRGB8888;
if (pMonitor->drmFormat == DRM_FORMAT_XRGB8888)
return DRM_FORMAT_XRGB8888;
if (pMonitor->drmFormat == DRM_FORMAT_XBGR8888)
return DRM_FORMAT_XBGR8888;
if (pMonitor->drmFormat == DRM_FORMAT_XBGR8888)
return DRM_FORMAT_XRGB8888;
if (pMonitor->drmFormat == DRM_FORMAT_XRGB2101010 || pMonitor->drmFormat == DRM_FORMAT_XBGR2101010)
return DRM_FORMAT_XBGR2101010;
return DRM_FORMAT_INVALID;