Warning, /plasma/kwin/src/wayland/protocols/frog-color-management-v1.xml is written in an unsupported language. File is not indexed.
0001 <?xml version="1.0" encoding="UTF-8"?> 0002 <protocol name="frog_color_management_v1"> 0003 0004 <copyright> 0005 Copyright © 2023 Joshua Ashton for Valve Software 0006 Copyright © 2023 Xaver Hugl 0007 0008 Permission is hereby granted, free of charge, to any person obtaining a 0009 copy of this software and associated documentation files (the "Software"), 0010 to deal in the Software without restriction, including without limitation 0011 the rights to use, copy, modify, merge, publish, distribute, sublicense, 0012 and/or sell copies of the Software, and to permit persons to whom the 0013 Software is furnished to do so, subject to the following conditions: 0014 0015 The above copyright notice and this permission notice (including the next 0016 paragraph) shall be included in all copies or substantial portions of the 0017 Software. 0018 0019 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 0020 IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 0021 FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL 0022 THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 0023 LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 0024 FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 0025 DEALINGS IN THE SOFTWARE. 0026 </copyright> 0027 0028 <description summary="experimental color management protocol"> 0029 The aim of this color management extension is to get HDR games working quickly, 0030 and have an easy way to test implementations in the wild before the upstream 0031 protocol is ready to be merged. 0032 For that purpose it's intentionally limited and cut down and does not serve 0033 all uses cases. 0034 </description> 0035 0036 <interface name="frog_color_management_factory_v1" version="1"> 0037 <description summary="color management factory"> 0038 The color management factory singleton creates color managed surface objects. 0039 </description> 0040 0041 <request name="destroy" type="destructor"></request> 0042 0043 <request name="get_color_managed_surface"> 0044 <description summary="create color management interface for surface"> 0045 </description> 0046 0047 <arg name="surface" type="object" interface="wl_surface" 0048 summary="target surface"/> 0049 <arg name="callback" type="new_id" interface="frog_color_managed_surface" 0050 summary="new color managed surface object"/> 0051 </request> 0052 </interface> 0053 0054 <interface name="frog_color_managed_surface" version="1"> 0055 <description summary="color managed surface"> 0056 Interface for changing surface color management and HDR state. 0057 0058 An implementation must: support every part of the version 0059 of the frog_color_managed_surface interface it exposes. 0060 Including all known enums associated with a given version. 0061 </description> 0062 0063 <request name="destroy" type="destructor"> 0064 <description summary="destroy color managed surface"> 0065 Destroying the color managed surface resets all known color 0066 state for the surface back to 'undefined' implementation-specific 0067 values. 0068 </description> 0069 </request> 0070 0071 <enum name="transfer_function"> 0072 <description summary="known transfer functions"> 0073 Extended information on the transfer functions described 0074 here can be found in the Khronos Data Format specification: 0075 0076 https://registry.khronos.org/DataFormat/specs/1.3/dataformat.1.3.html 0077 </description> 0078 <entry name="undefined" value="0" summary="specifies undefined, implementation-specific handling of the surface's transfer function."/> 0079 <entry name="srgb" value="1" summary="specifies the sRGB non-linear EOTF. An implementation may: display this as Gamma 2.2 for the purposes of being consistent with content rendering across displays, rendering_intent and user expectations."/> 0080 <entry name="gamma_22" value="2" summary="specifies gamma 2.2 power curve as the EOTF"/> 0081 <entry name="st2084_pq" value="3" summary="specifies the SMPTE ST2084 Perceptual Quantizer (PQ) EOTF"/> 0082 <entry name="scrgb_linear" value="4" summary="specifies the scRGB (extended sRGB) linear EOTF. Note: Primaries outside the gamut triangle specified can be expressed with negative values for this transfer function."/> 0083 </enum> 0084 0085 <request name="set_known_transfer_function"> 0086 <description summary="sets a known transfer function for a surface"/> 0087 <arg name="transfer_function" type="uint" enum="transfer_function" summary="transfer function for the surface"/> 0088 </request> 0089 0090 <enum name="primaries"> 0091 <description summary="known primaries"/> 0092 <entry name="undefined" value="0" summary="specifies undefined, implementation-specific handling"/> 0093 <entry name="rec709" value="1" summary="specifies Rec.709/sRGB primaries with D65 white point"/> 0094 <entry name="rec2020" value="2" summary="specifies Rec.2020/HDR10 primaries with D65 white point"/> 0095 </enum> 0096 0097 <request name="set_known_container_color_volume"> 0098 <description summary="sets the container color volume (primaries) for a surface"/> 0099 <arg name="primaries" type="uint" enum="primaries" summary="primaries for the surface"/> 0100 </request> 0101 0102 <enum name="render_intent"> 0103 <description summary="known render intents"> 0104 Extended information on render intents described 0105 here can be found in ICC.1:2022: 0106 0107 https://www.color.org/specification/ICC.1-2022-05.pdf 0108 </description> 0109 <entry name="perceptual" value="0" summary="perceptual"/> 0110 </enum> 0111 0112 <request name="set_render_intent"> 0113 <description summary="sets the render intent for a surface"> 0114 NOTE: On a surface with "perceptual" (default) render intent, handling of the container's color volume 0115 is implementation-specific, and may differ between different transfer functions it is paired with: 0116 ie. sRGB + 709 rendering may have it's primaries widened to more of the available display's gamut 0117 to be be more pleasing for the viewer. 0118 Compared to scRGB Linear + 709 being treated faithfully as 709 0119 (including utilizing negatives out of the 709 gamut triangle) 0120 </description> 0121 <arg name="render_intent" type="uint" enum="render_intent" summary="render intent for the surface"/> 0122 </request> 0123 0124 <request name="set_hdr_metadata"> 0125 <description summary="set HDR metadata for a surface"> 0126 Forwards HDR metadata from the client to the compositor. 0127 0128 HDR Metadata Infoframe as per CTA 861.G spec. 0129 0130 Usage of this HDR metadata is implementation specific and 0131 outside of the scope of this protocol. 0132 </description> 0133 <arg name="mastering_display_primary_red_x" type="uint"> 0134 <description summary="red primary x coordinate"> 0135 Mastering Red Color Primary X Coordinate of the Data. 0136 0137 Coded as unsigned 16-bit values in units of 0138 0.00002, where 0x0000 represents zero and 0xC350 0139 represents 1.0000. 0140 </description> 0141 </arg> 0142 <arg name="mastering_display_primary_red_y" type="uint"> 0143 <description summary="red primary y coordinate"> 0144 Mastering Red Color Primary Y Coordinate of the Data. 0145 0146 Coded as unsigned 16-bit values in units of 0147 0.00002, where 0x0000 represents zero and 0xC350 0148 represents 1.0000. 0149 </description> 0150 </arg> 0151 <arg name="mastering_display_primary_green_x" type="uint"> 0152 <description summary="green primary x coordinate"> 0153 Mastering Green Color Primary X Coordinate of the Data. 0154 0155 Coded as unsigned 16-bit values in units of 0156 0.00002, where 0x0000 represents zero and 0xC350 0157 represents 1.0000. 0158 </description> 0159 </arg> 0160 <arg name="mastering_display_primary_green_y" type="uint"> 0161 <description summary="green primary y coordinate"> 0162 Mastering Green Color Primary Y Coordinate of the Data. 0163 0164 Coded as unsigned 16-bit values in units of 0165 0.00002, where 0x0000 represents zero and 0xC350 0166 represents 1.0000. 0167 </description> 0168 </arg> 0169 <arg name="mastering_display_primary_blue_x" type="uint"> 0170 <description summary="blue primary x coordinate"> 0171 Mastering Blue Color Primary X Coordinate of the Data. 0172 0173 Coded as unsigned 16-bit values in units of 0174 0.00002, where 0x0000 represents zero and 0xC350 0175 represents 1.0000. 0176 </description> 0177 </arg> 0178 <arg name="mastering_display_primary_blue_y" type="uint"> 0179 <description summary="blue primary y coordinate"> 0180 Mastering Blue Color Primary Y Coordinate of the Data. 0181 0182 Coded as unsigned 16-bit values in units of 0183 0.00002, where 0x0000 represents zero and 0xC350 0184 represents 1.0000. 0185 </description> 0186 </arg> 0187 <arg name="mastering_white_point_x" type="uint"> 0188 <description summary="white point x coordinate"> 0189 Mastering White Point X Coordinate of the Data. 0190 0191 These are coded as unsigned 16-bit values in units of 0192 0.00002, where 0x0000 represents zero and 0xC350 0193 represents 1.0000. 0194 </description> 0195 </arg> 0196 <arg name="mastering_white_point_y" type="uint"> 0197 <description summary="white point y coordinate"> 0198 Mastering White Point Y Coordinate of the Data. 0199 0200 These are coded as unsigned 16-bit values in units of 0201 0.00002, where 0x0000 represents zero and 0xC350 0202 represents 1.0000. 0203 </description> 0204 </arg> 0205 <arg name="max_display_mastering_luminance" type="uint"> 0206 <description summary="max display mastering luminance"> 0207 Max Mastering Display Luminance. 0208 This value is coded as an unsigned 16-bit value in units of 1 cd/m2, 0209 where 0x0001 represents 1 cd/m2 and 0xFFFF represents 65535 cd/m2. 0210 </description> 0211 </arg> 0212 <arg name="min_display_mastering_luminance" type="uint"> 0213 <description summary="min display mastering luminance"> 0214 Min Mastering Display Luminance. 0215 This value is coded as an unsigned 16-bit value in units of 0216 0.0001 cd/m2, where 0x0001 represents 0.0001 cd/m2 and 0xFFFF 0217 represents 6.5535 cd/m2. 0218 </description> 0219 </arg> 0220 <arg name="max_cll" type="uint"> 0221 <description summary="max content light level"> 0222 Max Content Light Level. 0223 This value is coded as an unsigned 16-bit value in units of 1 cd/m2, 0224 where 0x0001 represents 1 cd/m2 and 0xFFFF represents 65535 cd/m2. 0225 </description> 0226 </arg> 0227 <arg name="max_fall" type="uint"> 0228 <description summary="max frame average light level"> 0229 Max Frame Average Light Level. 0230 This value is coded as an unsigned 16-bit value in units of 1 cd/m2, 0231 where 0x0001 represents 1 cd/m2 and 0xFFFF represents 65535 cd/m2. 0232 </description> 0233 </arg> 0234 </request> 0235 0236 <event name="preferred_metadata"> 0237 <description summary="preferred metadata for a surface"> 0238 Current preferred metadata for a surface. 0239 The application should use this information to tone-map its buffers 0240 to this target before committing. 0241 0242 This metadata does not necessarily correspond to any physical output, but 0243 rather what the compositor thinks would be best for a given surface. 0244 </description> 0245 <arg name="transfer_function" type="uint" enum="transfer_function"> 0246 <description summary="output's current transfer function"> 0247 Specifies a known transfer function that corresponds to the 0248 output the surface is targeting. 0249 </description> 0250 </arg> 0251 <arg name="output_display_primary_red_x" type="uint"> 0252 <description summary="red primary x coordinate"> 0253 Output Red Color Primary X Coordinate of the Data. 0254 0255 Coded as unsigned 16-bit values in units of 0256 0.00002, where 0x0000 represents zero and 0xC350 0257 represents 1.0000. 0258 </description> 0259 </arg> 0260 <arg name="output_display_primary_red_y" type="uint"> 0261 <description summary="red primary y coordinate"> 0262 Output Red Color Primary Y Coordinate of the Data. 0263 0264 Coded as unsigned 16-bit values in units of 0265 0.00002, where 0x0000 represents zero and 0xC350 0266 represents 1.0000. 0267 </description> 0268 </arg> 0269 <arg name="output_display_primary_green_x" type="uint"> 0270 <description summary="green primary x coordinate"> 0271 Output Green Color Primary X Coordinate of the Data. 0272 0273 Coded as unsigned 16-bit values in units of 0274 0.00002, where 0x0000 represents zero and 0xC350 0275 represents 1.0000. 0276 </description> 0277 </arg> 0278 <arg name="output_display_primary_green_y" type="uint"> 0279 <description summary="green primary y coordinate"> 0280 Output Green Color Primary Y Coordinate of the Data. 0281 0282 Coded as unsigned 16-bit values in units of 0283 0.00002, where 0x0000 represents zero and 0xC350 0284 represents 1.0000. 0285 </description> 0286 </arg> 0287 <arg name="output_display_primary_blue_x" type="uint"> 0288 <description summary="blue primary x coordinate"> 0289 Output Blue Color Primary X Coordinate of the Data. 0290 0291 Coded as unsigned 16-bit values in units of 0292 0.00002, where 0x0000 represents zero and 0xC350 0293 represents 1.0000. 0294 </description> 0295 </arg> 0296 <arg name="output_display_primary_blue_y" type="uint"> 0297 <description summary="blue primary y coordinate"> 0298 Output Blue Color Primary Y Coordinate of the Data. 0299 0300 Coded as unsigned 16-bit values in units of 0301 0.00002, where 0x0000 represents zero and 0xC350 0302 represents 1.0000. 0303 </description> 0304 </arg> 0305 <arg name="output_white_point_x" type="uint"> 0306 <description summary="white point x coordinate"> 0307 Output White Point X Coordinate of the Data. 0308 0309 These are coded as unsigned 16-bit values in units of 0310 0.00002, where 0x0000 represents zero and 0xC350 0311 represents 1.0000. 0312 </description> 0313 </arg> 0314 <arg name="output_white_point_y" type="uint"> 0315 <description summary="white point y coordinate"> 0316 Output White Point Y Coordinate of the Data. 0317 0318 These are coded as unsigned 16-bit values in units of 0319 0.00002, where 0x0000 represents zero and 0xC350 0320 represents 1.0000. 0321 </description> 0322 </arg> 0323 <arg name="max_luminance" type="uint"> 0324 <description summary="maximum luminance"> 0325 Max Output Luminance 0326 The max luminance in nits that the output is capable of rendering in small areas. 0327 Content should: not exceed this value to avoid clipping. 0328 0329 This value is coded as an unsigned 16-bit value in units of 1 cd/m2, 0330 where 0x0001 represents 1 cd/m2 and 0xFFFF represents 65535 cd/m2. 0331 </description> 0332 </arg> 0333 <arg name="min_luminance" type="uint"> 0334 <description summary="minimum luminance"> 0335 Min Output Luminance 0336 The min luminance that the output is capable of rendering. 0337 Content should: not exceed this value to avoid clipping. 0338 0339 This value is coded as an unsigned 16-bit value in units of 0340 0.0001 cd/m2, where 0x0001 represents 0.0001 cd/m2 and 0xFFFF 0341 represents 6.5535 cd/m2. 0342 </description> 0343 </arg> 0344 <arg name="max_full_frame_luminance" type="uint"> 0345 <description summary="maximum full frame luminance"> 0346 Max Full Frame Luminance 0347 The max luminance in nits that the output is capable of rendering for the 0348 full frame sustained. 0349 0350 This value is coded as an unsigned 16-bit value in units of 1 cd/m2, 0351 where 0x0001 represents 1 cd/m2 and 0xFFFF represents 65535 cd/m2. 0352 </description> 0353 </arg> 0354 </event> 0355 </interface> 0356 </protocol>