From 10754745a97c99449ef40db58bd425f5a91f9993 Mon Sep 17 00:00:00 2001 From: Vaxry <43317083+vaxerski@users.noreply.github.com> Date: Wed, 4 Mar 2026 19:50:28 +0000 Subject: render/cm: add ICC profile pipeline (#12711) Adds an ICC profile pipeline, loading via config and applying via 3D LUTs. --- src/protocols/GammaControl.cpp | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/protocols/GammaControl.cpp') diff --git a/src/protocols/GammaControl.cpp b/src/protocols/GammaControl.cpp index 2517c754..c28b881f 100644 --- a/src/protocols/GammaControl.cpp +++ b/src/protocols/GammaControl.cpp @@ -56,6 +56,12 @@ CGammaControl::CGammaControl(SP resource_, wl_resource* out LOGM(Log::DEBUG, "setGamma for {}", m_monitor->m_name); + if UNLIKELY (m_monitor->gammaRampsInUse()) { + LOGM(Log::ERR, "Monitor has gamma ramps in use (ICC?)"); + m_resource->sendFailed(); + return; + } + // TODO: make CFileDescriptor getflags use F_GETFL int fdFlags = fcntl(gammaFd.get(), F_GETFL, 0); if UNLIKELY (fdFlags < 0) { -- cgit v1.2.3