Warning, /libraries/plasma-wayland-protocols/src/protocols/kde-output-management-v2.xml is written in an unsupported language. File is not indexed.

0001 <?xml version="1.0" encoding="UTF-8"?>
0002 <protocol name="kde_output_management_v2">
0003   <copyright><![CDATA[
0004     SPDX-FileCopyrightText: 2008-2011 Kristian Høgsberg
0005     SPDX-FileCopyrightText: 2010-2011 Intel Corporation
0006     SPDX-FileCopyrightText: 2012-2013 Collabora, Ltd.
0007     SPDX-FileCopyrightText: 2015 Sebastian Kügler <sebas@kde.org>
0008     SPDX-FileCopyrightText: 2021 Méven Car <meven.car@enioka.com>
0009     SPDX-FileCopyrightText: 2023 Xaver Hugl <xaver.hugl@kde.org>
0010 
0011     SPDX-License-Identifier: MIT-CMU
0012     ]]></copyright>
0013 
0014 <interface name="kde_output_management_v2" version="7">
0015   <description summary="configuration of server outputs through clients">
0016     This interface enables clients to set properties of output devices for screen
0017     configuration purposes via the server. To this end output devices are referenced
0018     by global kde_output_device_v2 objects.
0019 
0020     outputmanagement (wl_global)
0021     --------------------------
0022     request:
0023     * create_configuration -> outputconfiguration (wl_resource)
0024 
0025     outputconfiguration (wl_resource)
0026     --------------------------
0027     requests:
0028     * enable(outputdevice, bool)
0029     * mode(outputdevice, mode)
0030     * transformation(outputdevice, flag)
0031     * position(outputdevice, x, y)
0032     * apply
0033 
0034     events:
0035     * applied
0036     * failed
0037 
0038     The server registers one outputmanagement object as a global object. In order
0039     to configure outputs a client requests create_configuration, which provides a
0040     resource referencing an outputconfiguration for one-time configuration. That
0041     way the server knows which requests belong together and can group them by that.
0042 
0043     On the outputconfiguration object the client calls for each output whether the
0044     output should be enabled, which mode should be set (by referencing the mode from
0045     the list of announced modes) and the output's global position. Once all outputs
0046     are configured that way, the client calls apply.
0047     At that point and not earlier the server should try to apply the configuration.
0048     If this succeeds the server emits the applied signal, otherwise the failed
0049     signal, such that the configuring client is noticed about the success of its
0050     configuration request.
0051 
0052     Through this design the interface enables atomic output configuration changes if
0053     internally supported by the server.
0054 
0055   </description>
0056   <request name="create_configuration">
0057     <description summary="provide outputconfiguration object for configuring outputs">
0058       Request an outputconfiguration object through which the client can configure
0059       output devices.
0060     </description>
0061     <arg name="id" type="new_id" interface="kde_output_configuration_v2"/>
0062   </request>
0063 
0064 </interface>
0065 
0066 <interface name="kde_output_configuration_v2" version="7">
0067   <description summary="configure single output devices">
0068     outputconfiguration is a client-specific resource that can be used to ask
0069     the server to apply changes to available output devices.
0070 
0071     The client receives a list of output devices from the registry. When it wants
0072     to apply new settings, it creates a configuration object from the
0073     outputmanagement global, writes changes through this object's enable, scale,
0074     transform and mode calls. It then asks the server to apply these settings in
0075     an atomic fashion, for example through Linux' DRM interface.
0076 
0077     The server signals back whether the new settings have applied successfully
0078     or failed to apply. outputdevice objects are updated after the changes have been
0079     applied to the hardware and before the server side sends the applied event.
0080   </description>
0081 
0082   <enum name="error">
0083     <description summary="kde_output_configuration_v2 error values">
0084       These error can be emitted in response to kde_output_configuration_v2 requests.
0085     </description>
0086     <entry name="already_applied" value="0" summary="the config is already applied"/>
0087   </enum>
0088 
0089   <request name="enable">
0090     <description summary="enable or disable an output">
0091       Mark the output as enabled or disabled.
0092     </description>
0093     <arg name="outputdevice" type="object" interface="kde_output_device_v2" summary="outputdevice to be en- or disabled"/>
0094     <arg name="enable" type="int" summary="1 to enable or 0 to disable this output"/>
0095   </request>
0096 
0097   <request name="mode">
0098     <description summary="switch output-device to mode">
0099       Sets the mode for a given output.
0100     </description>
0101     <arg name="outputdevice" type="object" interface="kde_output_device_v2" summary="outputdevice this mode change applies to"/>
0102     <arg name="mode" type="object" interface="kde_output_device_mode_v2" summary="the mode to apply"/>
0103   </request>
0104 
0105   <request name="transform">
0106     <description summary="transform output-device">
0107       Sets the transformation for a given output.
0108     </description>
0109     <arg name="outputdevice" type="object" interface="kde_output_device_v2" summary="outputdevice this transformation change applies to"/>
0110     <arg name="transform" type="int" summary="transform enum"/>
0111   </request>
0112 
0113   <request name="position">
0114     <description summary="position output in global space">
0115       Sets the position for this output device. (x,y) describe the top-left corner
0116       of the output in global space, whereby the origin (0,0) of the global space
0117       has to be aligned with the top-left corner of the most left and in case this
0118       does not define a single one the top output.
0119 
0120       There may be no gaps or overlaps between outputs, i.e. the outputs are
0121       stacked horizontally, vertically, or both on each other.
0122     </description>
0123     <arg name="outputdevice" type="object" interface="kde_output_device_v2" summary="outputdevice this position applies to"/>
0124     <arg name="x" type="int" summary="position on the x-axis"/>
0125     <arg name="y" type="int" summary="position on the y-axis"/>
0126   </request>
0127 
0128   <request name="scale">
0129     <description summary="set scaling factor of this output">
0130       Sets the scaling factor for this output device.
0131     </description>
0132     <arg name="outputdevice" type="object" interface="kde_output_device_v2" summary="outputdevice this scale change applies to"/>
0133     <arg name="scale" type="fixed" summary="scaling factor"/>
0134   </request>
0135 
0136   <request name="apply">
0137     <description summary="apply configuration changes to all output devices">
0138       Asks the server to apply property changes requested through this outputconfiguration
0139       object to all outputs on the server side.
0140 
0141       The output configuration can be applied only once. The already_applied protocol error
0142       will be posted if the apply request is called the second time.
0143     </description>
0144   </request>
0145 
0146   <event name="applied">
0147     <description summary="configuration changes have been applied">
0148       Sent after the server has successfully applied the changes.
0149       .
0150     </description>
0151   </event>
0152 
0153   <event name="failed">
0154     <description summary="configuration changes failed to apply">
0155       Sent if the server rejects the changes or failed to apply them.
0156     </description>
0157   </event>
0158 
0159   <request name="destroy" type="destructor">
0160     <description summary="release the outputconfiguration object"/>
0161   </request>
0162 
0163   <request name="overscan">
0164     <description summary="set overscan value">
0165       Set the overscan value of this output device with a value in percent.
0166     </description>
0167     <arg name="outputdevice" type="object" interface="kde_output_device_v2" summary="outputdevice overscan applies to"/>
0168     <arg name="overscan" type="uint" summary="overscan value"/>
0169   </request>
0170   
0171   <enum name="vrr_policy">
0172     <description summary="describes vrr policy">
0173       Describes when the compositor may employ variable refresh rate
0174     </description>
0175     <entry name="never" value="0"/>
0176     <entry name="always" value="1"/>
0177     <entry name="automatic" value="2"/>
0178   </enum>
0179 
0180   <request name="set_vrr_policy">
0181     <description summary="set the VRR policy">
0182       Set what policy the compositor should employ regarding its use of
0183       variable refresh rate.
0184     </description>
0185     <arg name="outputdevice" type="object" interface="kde_output_device_v2" summary="outputdevice this VRR policy applies to"/>
0186     <arg name="policy" type="uint" enum="vrr_policy" summary="the vrr policy to apply"/>
0187   </request>
0188 
0189   <enum name="rgb_range">
0190     <description summary="describes RGB range policy">
0191       Whether this output should use full or limited rgb.
0192     </description>
0193     <entry name="automatic" value="0"/>
0194     <entry name="full" value="1"/>
0195     <entry name="limited" value="2"/>
0196   </enum>
0197 
0198   <request name="set_rgb_range">
0199     <description summary="RGB range">
0200       Whether full or limited color range should be used
0201     </description>
0202     <arg name="outputdevice" type="object" interface="kde_output_device_v2" summary="outputdevice the rgb range applies to"/>
0203     <arg name="rgb_range" type="uint" enum="rgb_range"/>
0204   </request>
0205 
0206   <request name="set_primary_output" since="2">
0207     <description summary="Select which primary output to use" />
0208     <arg name="output" type="object" interface="kde_output_device_v2" allow-null="false"/>
0209   </request>
0210 
0211   <request name="set_priority" since="3">
0212     <description summary="Set the order of outputs">
0213       The order of outputs can be used to assign desktop environment components to a specific screen,
0214       see kde_output_order_v1 for details. The priority is 1-based for outputs that will be enabled after
0215       this changeset is applied, all outputs that are disabled need to have the index set to zero.
0216     </description>
0217     <arg name="outputdevice" type="object" interface="kde_output_device_v2" summary="outputdevice the index applies to" />
0218     <arg name="priority" type="uint" summary="the priority of the output" />
0219   </request>
0220 
0221   <request name="set_high_dynamic_range" since="4">
0222     <description summary="change if HDR should be enabled">
0223       Sets whether or not the output should be set to HDR mode.
0224     </description>
0225     <arg name="outputdevice" type="object" interface="kde_output_device_v2" summary="outputdevice this setting applies to"/>
0226     <arg name="enable_hdr" type="uint" summary="1 to enable, 0 to disable hdr"/>
0227   </request>
0228 
0229   <request name="set_sdr_brightness" since="4">
0230     <description summary="set the brightness for sdr content">
0231       Sets the brightness of standard dynamic range content in nits. Only has an effect while the output is in HDR mode.
0232       Note that while the value is in nits, that doesn't necessarily translate to the same brightness on the screen.
0233     </description>
0234     <arg name="outputdevice" type="object" interface="kde_output_device_v2" summary="outputdevice this setting applies to"/>
0235     <arg name="sdr_brightness" type="uint"/>
0236   </request>
0237 
0238   <request name="set_wide_color_gamut" since="4">
0239     <description summary="change if a wide color gamut should be used">
0240       Whether or not the output should use a wide color gamut
0241     </description>
0242     <arg name="outputdevice" type="object" interface="kde_output_device_v2" summary="outputdevice this setting applies to"/>
0243     <arg name="enable_wcg" type="uint" summary="1 to enable, 0 to disable wcg"/>
0244   </request>
0245 
0246   <enum name="auto_rotate_policy">
0247     <description summary="describes when auto rotate should be used"/>
0248     <entry name="never" value="0"/>
0249     <entry name="in_tablet_mode" value="1"/>
0250     <entry name="always" value="2"/>
0251   </enum>
0252 
0253   <request name="set_auto_rotate_policy" since="5">
0254     <description summary="change when auto rotate should be used"/>
0255     <arg name="outputdevice" type="object" interface="kde_output_device_v2" summary="outputdevice this setting applies to"/>
0256     <arg name="policy" type="uint" enum="auto_rotate_policy"/>
0257   </request>
0258 
0259   <request name="set_icc_profile_path" since="6">
0260     <description summary="change the used icc profile"/>
0261     <arg name="outputdevice" type="object" interface="kde_output_device_v2" summary="outputdevice this setting applies to"/>
0262     <arg name="profile_path" type="string"/>
0263   </request>
0264 
0265   <request name="set_brightness_overrides" since="7">
0266     <description summary="override metadata about the screen's brightness limits"/>
0267     <arg name="outputdevice" type="object" interface="kde_output_device_v2" summary="outputdevice this setting applies to"/>
0268     <arg name="max_peak_brightness" type="int" summary="-1 for not overriding, or positive values in nits"/>
0269     <arg name="max_frame_average_brightness" type="int" summary="-1 for not overriding, or positive values in nits"/>
0270     <arg name="min_brightness" type="int" summary="-1 for not overriding, or positive values in 0.0001 nits"/>
0271   </request>
0272 
0273   <request name="set_sdr_gamut_wideness" since="7">
0274     <description summary="describes which gamut is assumed for sRGB applications">
0275       This can be used to provide the colors users assume sRGB applications should have based on the
0276       default experience on many modern sRGB screens.
0277     </description>
0278     <arg name="outputdevice" type="object" interface="kde_output_device_v2" summary="outputdevice this setting applies to"/>
0279     <arg name="gamut_wideness" type="uint" summary="0 means rec.709 primaries, 10000 means native primaries"/>
0280   </request>
0281 </interface>
0282 </protocol>