backends/drm: don't advertise support for wide color gamut on Intel
i915 doesn't implement the Colorspace property correctly, so exposing this feature makes it look like our HDR implementation is broken. This hides the HDR checkbox in system settings until Intel fixes their driver For testing purposes, users can still opt into this with the environment variable KWIN_DRM_ALLOW_INTEL_COLORSPACE.
This commit is contained in:
parent
9ea6f311ea
commit
742268bfa1
1 changed files with 5 additions and 1 deletions
|
@ -35,6 +35,8 @@
|
|||
namespace KWin
|
||||
{
|
||||
|
||||
static const bool s_allowColorspaceIntel = qEnvironmentVariableIntValue("KWIN_DRM_ALLOW_INTEL_COLORSPACE") == 1;
|
||||
|
||||
DrmOutput::DrmOutput(const std::shared_ptr<DrmConnector> &conn)
|
||||
: DrmAbstractOutput(conn->gpu())
|
||||
, m_pipeline(conn->pipeline())
|
||||
|
@ -64,7 +66,9 @@ DrmOutput::DrmOutput(const std::shared_ptr<DrmConnector> &conn)
|
|||
capabilities |= Capability::HighDynamicRange;
|
||||
}
|
||||
if (m_connector->colorspace.isValid() && m_connector->colorspace.hasEnum(DrmConnector::Colorspace::BT2020_RGB) && m_connector->edid()->supportsBT2020()) {
|
||||
capabilities |= Capability::WideColorGamut;
|
||||
if (!m_gpu->isI915() || s_allowColorspaceIntel) {
|
||||
capabilities |= Capability::WideColorGamut;
|
||||
}
|
||||
}
|
||||
if (conn->isInternal()) {
|
||||
// TODO only set this if an orientation sensor is available?
|
||||
|
|
Loading…
Reference in a new issue