|
| 1 | +<?xml version="1.0" encoding="UTF-8"?> |
| 2 | +<protocol name="ext_background_effect_v1"> |
| 3 | + <copyright> |
| 4 | + Copyright (C) 2015 Martin Gräßlin |
| 5 | + Copyright (C) 2015 Marco Martin |
| 6 | + Copyright (C) 2020 Vlad Zahorodnii |
| 7 | + Copyright (C) 2024 Xaver Hugl |
| 8 | + |
| 9 | + Permission is hereby granted, free of charge, to any person obtaining a |
| 10 | + copy of this software and associated documentation files (the "Software"), |
| 11 | + to deal in the Software without restriction, including without limitation |
| 12 | + the rights to use, copy, modify, merge, publish, distribute, sublicense, |
| 13 | + and/or sell copies of the Software, and to permit persons to whom the |
| 14 | + Software is furnished to do so, subject to the following conditions: |
| 15 | + |
| 16 | + The above copyright notice and this permission notice (including the next |
| 17 | + paragraph) shall be included in all copies or substantial portions of the |
| 18 | + Software. |
| 19 | + |
| 20 | + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR |
| 21 | + IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, |
| 22 | + FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL |
| 23 | + THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER |
| 24 | + LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING |
| 25 | + FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER |
| 26 | + DEALINGS IN THE SOFTWARE. |
| 27 | + </copyright> |
| 28 | + |
| 29 | + <description summary="background effect protocol"> |
| 30 | + This protocol provides a way to improve visuals of translucent surfaces |
| 31 | + by applying effects like blur to the background behind them. |
| 32 | + |
| 33 | + The capabilities are send when the global is bound, and every time they |
| 34 | + change. Note that when the capability goes away, the corresponding effect |
| 35 | + is no longer applied by the compositor, even if it was set before. |
| 36 | + |
| 37 | + Warning! The protocol described in this file is currently in the testing |
| 38 | + phase. Backward compatible changes may be added together with the |
| 39 | + corresponding interface version bump. Backward incompatible changes can |
| 40 | + only be done by creating a new major version of the extension. |
| 41 | + </description> |
| 42 | + |
| 43 | + <interface name="ext_background_effect_manager_v1" version="1"> |
| 44 | + <description summary="background effect factory"> |
| 45 | + This protocol provides a way to improve visuals of translucent surfaces |
| 46 | + by applying effects like blur to the background behind them. |
| 47 | + </description> |
| 48 | + |
| 49 | + <enum name="error"> |
| 50 | + <entry name="background_effect_exists" value="0" |
| 51 | + summary="the surface already has a background effect object"/> |
| 52 | + </enum> |
| 53 | + |
| 54 | + <enum name="capability" bitfield="true"> |
| 55 | + <description summary="compositor capabilities"> |
| 56 | + These flags indicate which background effect features the compositor |
| 57 | + supports. |
| 58 | + </description> |
| 59 | + <entry name="blur" value="1" summary="the compositor supports applying blur"/> |
| 60 | + </enum> |
| 61 | + |
| 62 | + <event name="capabilities"> |
| 63 | + <description summary="capabilities of the compositor"> |
| 64 | + Advertises the capabilities of the compositor. |
| 65 | + </description> |
| 66 | + <arg name="flags" type="uint" enum="capability" |
| 67 | + summary="capabilities of the compositor"/> |
| 68 | + </event> |
| 69 | + |
| 70 | + <request name="destroy" type="destructor"> |
| 71 | + <description summary="destroy the background effect manager"> |
| 72 | + Informs the server that the client will no longer be using this |
| 73 | + protocol object. Existing objects created by this object are not |
| 74 | + affected. |
| 75 | + </description> |
| 76 | + </request> |
| 77 | + |
| 78 | + <request name="get_background_effect"> |
| 79 | + <description summary="get a background effects object"> |
| 80 | + Instantiate an interface extension for the given wl_surface to add |
| 81 | + effects like blur for the background behind it. |
| 82 | + |
| 83 | + If the given wl_surface already has a ext_background_effect_surface_v1 |
| 84 | + object associated, the background_effect_exists protocol error will be |
| 85 | + raised. |
| 86 | + </description> |
| 87 | + <arg name="id" type="new_id" interface="ext_background_effect_surface_v1" |
| 88 | + summary="the new ext_background_effect_surface_v1 object"/> |
| 89 | + <arg name="surface" type="object" interface="wl_surface" |
| 90 | + summary="the surface"/> |
| 91 | + </request> |
| 92 | + </interface> |
| 93 | + |
| 94 | + <interface name="ext_background_effect_surface_v1" version="1"> |
| 95 | + <description summary="background effects for a surface"> |
| 96 | + The background effect object provides a way to specify a region behind a |
| 97 | + surface that should have background effects like blur applied. |
| 98 | + |
| 99 | + If the wl_surface associated with the ext_background_effect_surface_v1 |
| 100 | + object has been destroyed, this object becomes inert. |
| 101 | + </description> |
| 102 | + |
| 103 | + <enum name="error"> |
| 104 | + <entry name="surface_destroyed" value="0" |
| 105 | + summary="the associated surface has been destroyed"/> |
| 106 | + </enum> |
| 107 | + |
| 108 | + <request name="destroy" type="destructor"> |
| 109 | + <description summary="release the blur object"> |
| 110 | + Informs the server that the client will no longer be using this |
| 111 | + protocol object. The effect regions will be removed on the next |
| 112 | + commit. |
| 113 | + </description> |
| 114 | + </request> |
| 115 | + |
| 116 | + <request name="set_blur_region"> |
| 117 | + <description summary="set blur region"> |
| 118 | + This request sets the region of the surface that will have its |
| 119 | + background blurred. |
| 120 | + |
| 121 | + The blur region is specified in the surface-local coordinates, and |
| 122 | + clipped by the compositor to the surface size. |
| 123 | + |
| 124 | + The initial value for the blur region is empty. Setting the pending |
| 125 | + blur region has copy semantics, and the wl_region object can be |
| 126 | + destroyed immediately. A NULL wl_region removes the effect. |
| 127 | + |
| 128 | + The blur region is double-buffered state, and will be applied on the |
| 129 | + next wl_surface.commit. |
| 130 | + |
| 131 | + The blur algorithm is subject to compositor policies. |
| 132 | + |
| 133 | + If the associated surface has been destroyed, the surface_destroyed |
| 134 | + error will be raised. |
| 135 | + </description> |
| 136 | + <arg name="region" type="object" interface="wl_region" |
| 137 | + summary="blur region of the surface" allow-null="true"/> |
| 138 | + </request> |
| 139 | + </interface> |
| 140 | +</protocol> |
0 commit comments