backends/drm: don't do direct scanout when HDR brightness isn't 1

Otherwise the brightness multiplier doesn't get applied
This commit is contained in:
Xaver Hugl 2024-06-16 17:11:43 +02:00
parent 979ac5bd50
commit 178d49093c

View file

@ -90,7 +90,7 @@ bool EglGbmLayer::doAttemptScanout(GraphicsBuffer *buffer, const ColorDescriptio
if (directScanoutDisabled) {
return false;
}
if (m_pipeline->output()->channelFactors() != QVector3D(1, 1, 1) || m_pipeline->iccProfile()) {
if (m_pipeline->output()->channelFactors() != QVector3D(1, 1, 1) || (m_pipeline->output()->highDynamicRange() && m_pipeline->output()->brightness() != 1) || m_pipeline->iccProfile()) {
// TODO use GAMMA_LUT, CTM and DEGAMMA_LUT to allow direct scanout with HDR
return false;
}