experimental:wp_cm_1_2

This commit is contained in:
UjinT34 2026-01-02 21:30:21 +03:00
parent 91b91eb78f
commit facfd8471d
3 changed files with 15 additions and 1 deletions

View file

@ -822,6 +822,8 @@ CConfigManager::CConfigManager() {
registerConfigVar("ecosystem:no_donation_nag", Hyprlang::INT{0});
registerConfigVar("ecosystem:enforce_permissions", Hyprlang::INT{0});
registerConfigVar("experimental:wp_cm_1_2", Hyprlang::INT{0});
registerConfigVar("quirks:prefer_hdr", Hyprlang::INT{0});
registerConfigVar("quirks:skip_non_kms_dmabuf_formats", Hyprlang::INT{0});

View file

@ -2208,6 +2208,17 @@ namespace Config::Supplementary {
.data = SConfigOptionDescription::SBoolData{.value = true},
},
/*
* Experimental
*/
SConfigOptionDescription{
.value = "experimental:wp_cm_1_2",
.description = "Allow wp-cm-v1 version 2",
.type = CONFIG_OPTION_BOOL,
.data = SConfigOptionDescription::SBoolData{false},
},
/*
* Quirks
*/

View file

@ -109,6 +109,7 @@ CProtocolManager::CProtocolManager() {
static const auto PENABLECM = CConfigValue<Hyprlang::INT>("render:cm_enabled");
static const auto PDEBUGCM = CConfigValue<Hyprlang::INT>("debug:full_cm_proto");
static const auto PCMV1_2 = CConfigValue<Hyprlang::INT>("experimental:wp_cm_1_2");
static const auto PENABLECT = CConfigValue<Hyprlang::INT>("render:commit_timing_enabled");
@ -205,7 +206,7 @@ CProtocolManager::CProtocolManager() {
PROTO::imageCopyCapture = makeUnique<CImageCopyCaptureProtocol>(&ext_image_copy_capture_manager_v1_interface, 1, "ImageCopyCapture");
if (*PENABLECM)
PROTO::colorManagement = makeUnique<CColorManagementProtocol>(&wp_color_manager_v1_interface, 2, "ColorManagement", *PDEBUGCM);
PROTO::colorManagement = makeUnique<CColorManagementProtocol>(&wp_color_manager_v1_interface, *PCMV1_2 ? 2 : 1, "ColorManagement", *PDEBUGCM);
// ! please read the top of this file before adding another protocol