1bf215546Sopenharmony_ci<?xml version="1.0" encoding="UTF-8"?> 2bf215546Sopenharmony_ci<protocol name="drm"> 3bf215546Sopenharmony_ci 4bf215546Sopenharmony_ci <copyright> 5bf215546Sopenharmony_ci Copyright © 2008-2011 Kristian Høgsberg 6bf215546Sopenharmony_ci Copyright © 2010-2011 Intel Corporation 7bf215546Sopenharmony_ci 8bf215546Sopenharmony_ci Permission to use, copy, modify, distribute, and sell this 9bf215546Sopenharmony_ci software and its documentation for any purpose is hereby granted 10bf215546Sopenharmony_ci without fee, provided that\n the above copyright notice appear in 11bf215546Sopenharmony_ci all copies and that both that copyright notice and this permission 12bf215546Sopenharmony_ci notice appear in supporting documentation, and that the name of 13bf215546Sopenharmony_ci the copyright holders not be used in advertising or publicity 14bf215546Sopenharmony_ci pertaining to distribution of the software without specific, 15bf215546Sopenharmony_ci written prior permission. The copyright holders make no 16bf215546Sopenharmony_ci representations about the suitability of this software for any 17bf215546Sopenharmony_ci purpose. It is provided "as is" without express or implied 18bf215546Sopenharmony_ci warranty. 19bf215546Sopenharmony_ci 20bf215546Sopenharmony_ci THE COPYRIGHT HOLDERS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS 21bf215546Sopenharmony_ci SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND 22bf215546Sopenharmony_ci FITNESS, IN NO EVENT SHALL THE COPYRIGHT HOLDERS BE LIABLE FOR ANY 23bf215546Sopenharmony_ci SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES 24bf215546Sopenharmony_ci WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN 25bf215546Sopenharmony_ci AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, 26bf215546Sopenharmony_ci ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF 27bf215546Sopenharmony_ci THIS SOFTWARE. 28bf215546Sopenharmony_ci </copyright> 29bf215546Sopenharmony_ci 30bf215546Sopenharmony_ci <!-- drm support. This object is created by the server and published 31bf215546Sopenharmony_ci using the display's global event. --> 32bf215546Sopenharmony_ci <interface name="wl_drm" version="2"> 33bf215546Sopenharmony_ci <enum name="error"> 34bf215546Sopenharmony_ci <entry name="authenticate_fail" value="0"/> 35bf215546Sopenharmony_ci <entry name="invalid_format" value="1"/> 36bf215546Sopenharmony_ci <entry name="invalid_name" value="2"/> 37bf215546Sopenharmony_ci </enum> 38bf215546Sopenharmony_ci 39bf215546Sopenharmony_ci <enum name="format"> 40bf215546Sopenharmony_ci <!-- The drm format codes match the #defines in drm_fourcc.h. 41bf215546Sopenharmony_ci The formats actually supported by the compositor will be 42bf215546Sopenharmony_ci reported by the format event. New codes must not be added, 43bf215546Sopenharmony_ci unless directly taken from drm_fourcc.h. --> 44bf215546Sopenharmony_ci <entry name="c8" value="0x20203843"/> 45bf215546Sopenharmony_ci <entry name="rgb332" value="0x38424752"/> 46bf215546Sopenharmony_ci <entry name="bgr233" value="0x38524742"/> 47bf215546Sopenharmony_ci <entry name="xrgb4444" value="0x32315258"/> 48bf215546Sopenharmony_ci <entry name="xbgr4444" value="0x32314258"/> 49bf215546Sopenharmony_ci <entry name="rgbx4444" value="0x32315852"/> 50bf215546Sopenharmony_ci <entry name="bgrx4444" value="0x32315842"/> 51bf215546Sopenharmony_ci <entry name="argb4444" value="0x32315241"/> 52bf215546Sopenharmony_ci <entry name="abgr4444" value="0x32314241"/> 53bf215546Sopenharmony_ci <entry name="rgba4444" value="0x32314152"/> 54bf215546Sopenharmony_ci <entry name="bgra4444" value="0x32314142"/> 55bf215546Sopenharmony_ci <entry name="xrgb1555" value="0x35315258"/> 56bf215546Sopenharmony_ci <entry name="xbgr1555" value="0x35314258"/> 57bf215546Sopenharmony_ci <entry name="rgbx5551" value="0x35315852"/> 58bf215546Sopenharmony_ci <entry name="bgrx5551" value="0x35315842"/> 59bf215546Sopenharmony_ci <entry name="argb1555" value="0x35315241"/> 60bf215546Sopenharmony_ci <entry name="abgr1555" value="0x35314241"/> 61bf215546Sopenharmony_ci <entry name="rgba5551" value="0x35314152"/> 62bf215546Sopenharmony_ci <entry name="bgra5551" value="0x35314142"/> 63bf215546Sopenharmony_ci <entry name="rgb565" value="0x36314752"/> 64bf215546Sopenharmony_ci <entry name="bgr565" value="0x36314742"/> 65bf215546Sopenharmony_ci <entry name="rgb888" value="0x34324752"/> 66bf215546Sopenharmony_ci <entry name="bgr888" value="0x34324742"/> 67bf215546Sopenharmony_ci <entry name="xrgb8888" value="0x34325258"/> 68bf215546Sopenharmony_ci <entry name="xbgr8888" value="0x34324258"/> 69bf215546Sopenharmony_ci <entry name="rgbx8888" value="0x34325852"/> 70bf215546Sopenharmony_ci <entry name="bgrx8888" value="0x34325842"/> 71bf215546Sopenharmony_ci <entry name="argb8888" value="0x34325241"/> 72bf215546Sopenharmony_ci <entry name="abgr8888" value="0x34324241"/> 73bf215546Sopenharmony_ci <entry name="rgba8888" value="0x34324152"/> 74bf215546Sopenharmony_ci <entry name="bgra8888" value="0x34324142"/> 75bf215546Sopenharmony_ci <entry name="xrgb2101010" value="0x30335258"/> 76bf215546Sopenharmony_ci <entry name="xbgr2101010" value="0x30334258"/> 77bf215546Sopenharmony_ci <entry name="rgbx1010102" value="0x30335852"/> 78bf215546Sopenharmony_ci <entry name="bgrx1010102" value="0x30335842"/> 79bf215546Sopenharmony_ci <entry name="argb2101010" value="0x30335241"/> 80bf215546Sopenharmony_ci <entry name="abgr2101010" value="0x30334241"/> 81bf215546Sopenharmony_ci <entry name="rgba1010102" value="0x30334152"/> 82bf215546Sopenharmony_ci <entry name="bgra1010102" value="0x30334142"/> 83bf215546Sopenharmony_ci <entry name="yuyv" value="0x56595559"/> 84bf215546Sopenharmony_ci <entry name="yvyu" value="0x55595659"/> 85bf215546Sopenharmony_ci <entry name="uyvy" value="0x59565955"/> 86bf215546Sopenharmony_ci <entry name="vyuy" value="0x59555956"/> 87bf215546Sopenharmony_ci <entry name="ayuv" value="0x56555941"/> 88bf215546Sopenharmony_ci <entry name="xyuv8888" value="0x56555958"/> 89bf215546Sopenharmony_ci <entry name="nv12" value="0x3231564e"/> 90bf215546Sopenharmony_ci <entry name="nv21" value="0x3132564e"/> 91bf215546Sopenharmony_ci <entry name="nv16" value="0x3631564e"/> 92bf215546Sopenharmony_ci <entry name="nv61" value="0x3136564e"/> 93bf215546Sopenharmony_ci <entry name="yuv410" value="0x39565559"/> 94bf215546Sopenharmony_ci <entry name="yvu410" value="0x39555659"/> 95bf215546Sopenharmony_ci <entry name="yuv411" value="0x31315559"/> 96bf215546Sopenharmony_ci <entry name="yvu411" value="0x31315659"/> 97bf215546Sopenharmony_ci <entry name="yuv420" value="0x32315559"/> 98bf215546Sopenharmony_ci <entry name="yvu420" value="0x32315659"/> 99bf215546Sopenharmony_ci <entry name="yuv422" value="0x36315559"/> 100bf215546Sopenharmony_ci <entry name="yvu422" value="0x36315659"/> 101bf215546Sopenharmony_ci <entry name="yuv444" value="0x34325559"/> 102bf215546Sopenharmony_ci <entry name="yvu444" value="0x34325659"/> 103bf215546Sopenharmony_ci <entry name="abgr16f" value="0x48344241"/> 104bf215546Sopenharmony_ci <entry name="xbgr16f" value="0x48344258"/> 105bf215546Sopenharmony_ci </enum> 106bf215546Sopenharmony_ci 107bf215546Sopenharmony_ci <!-- Call this request with the magic received from drmGetMagic(). 108bf215546Sopenharmony_ci It will be passed on to the drmAuthMagic() or 109bf215546Sopenharmony_ci DRIAuthConnection() call. This authentication must be 110bf215546Sopenharmony_ci completed before create_buffer could be used. --> 111bf215546Sopenharmony_ci <request name="authenticate"> 112bf215546Sopenharmony_ci <arg name="id" type="uint"/> 113bf215546Sopenharmony_ci </request> 114bf215546Sopenharmony_ci 115bf215546Sopenharmony_ci <!-- Create a wayland buffer for the named DRM buffer. The DRM 116bf215546Sopenharmony_ci surface must have a name using the flink ioctl --> 117bf215546Sopenharmony_ci <request name="create_buffer"> 118bf215546Sopenharmony_ci <arg name="id" type="new_id" interface="wl_buffer"/> 119bf215546Sopenharmony_ci <arg name="name" type="uint"/> 120bf215546Sopenharmony_ci <arg name="width" type="int"/> 121bf215546Sopenharmony_ci <arg name="height" type="int"/> 122bf215546Sopenharmony_ci <arg name="stride" type="uint"/> 123bf215546Sopenharmony_ci <arg name="format" type="uint"/> 124bf215546Sopenharmony_ci </request> 125bf215546Sopenharmony_ci 126bf215546Sopenharmony_ci <!-- Create a wayland buffer for the named DRM buffer. The DRM 127bf215546Sopenharmony_ci surface must have a name using the flink ioctl --> 128bf215546Sopenharmony_ci <request name="create_planar_buffer"> 129bf215546Sopenharmony_ci <arg name="id" type="new_id" interface="wl_buffer"/> 130bf215546Sopenharmony_ci <arg name="name" type="uint"/> 131bf215546Sopenharmony_ci <arg name="width" type="int"/> 132bf215546Sopenharmony_ci <arg name="height" type="int"/> 133bf215546Sopenharmony_ci <arg name="format" type="uint"/> 134bf215546Sopenharmony_ci <arg name="offset0" type="int"/> 135bf215546Sopenharmony_ci <arg name="stride0" type="int"/> 136bf215546Sopenharmony_ci <arg name="offset1" type="int"/> 137bf215546Sopenharmony_ci <arg name="stride1" type="int"/> 138bf215546Sopenharmony_ci <arg name="offset2" type="int"/> 139bf215546Sopenharmony_ci <arg name="stride2" type="int"/> 140bf215546Sopenharmony_ci </request> 141bf215546Sopenharmony_ci 142bf215546Sopenharmony_ci <!-- Notification of the path of the drm device which is used by 143bf215546Sopenharmony_ci the server. The client should use this device for creating 144bf215546Sopenharmony_ci local buffers. Only buffers created from this device should 145bf215546Sopenharmony_ci be be passed to the server using this drm object's 146bf215546Sopenharmony_ci create_buffer request. --> 147bf215546Sopenharmony_ci <event name="device"> 148bf215546Sopenharmony_ci <arg name="name" type="string"/> 149bf215546Sopenharmony_ci </event> 150bf215546Sopenharmony_ci 151bf215546Sopenharmony_ci <event name="format"> 152bf215546Sopenharmony_ci <arg name="format" type="uint"/> 153bf215546Sopenharmony_ci </event> 154bf215546Sopenharmony_ci 155bf215546Sopenharmony_ci <!-- Raised if the authenticate request succeeded --> 156bf215546Sopenharmony_ci <event name="authenticated"/> 157bf215546Sopenharmony_ci 158bf215546Sopenharmony_ci <enum name="capability" since="2"> 159bf215546Sopenharmony_ci <description summary="wl_drm capability bitmask"> 160bf215546Sopenharmony_ci Bitmask of capabilities. 161bf215546Sopenharmony_ci </description> 162bf215546Sopenharmony_ci <entry name="prime" value="1" summary="wl_drm prime available"/> 163bf215546Sopenharmony_ci </enum> 164bf215546Sopenharmony_ci 165bf215546Sopenharmony_ci <event name="capabilities"> 166bf215546Sopenharmony_ci <arg name="value" type="uint"/> 167bf215546Sopenharmony_ci </event> 168bf215546Sopenharmony_ci 169bf215546Sopenharmony_ci <!-- Version 2 additions --> 170bf215546Sopenharmony_ci 171bf215546Sopenharmony_ci <!-- Create a wayland buffer for the prime fd. Use for regular and planar 172bf215546Sopenharmony_ci buffers. Pass 0 for offset and stride for unused planes. --> 173bf215546Sopenharmony_ci <request name="create_prime_buffer" since="2"> 174bf215546Sopenharmony_ci <arg name="id" type="new_id" interface="wl_buffer"/> 175bf215546Sopenharmony_ci <arg name="name" type="fd"/> 176bf215546Sopenharmony_ci <arg name="width" type="int"/> 177bf215546Sopenharmony_ci <arg name="height" type="int"/> 178bf215546Sopenharmony_ci <arg name="format" type="uint"/> 179bf215546Sopenharmony_ci <arg name="offset0" type="int"/> 180bf215546Sopenharmony_ci <arg name="stride0" type="int"/> 181bf215546Sopenharmony_ci <arg name="offset1" type="int"/> 182bf215546Sopenharmony_ci <arg name="stride1" type="int"/> 183bf215546Sopenharmony_ci <arg name="offset2" type="int"/> 184bf215546Sopenharmony_ci <arg name="stride2" type="int"/> 185bf215546Sopenharmony_ci </request> 186bf215546Sopenharmony_ci 187bf215546Sopenharmony_ci </interface> 188bf215546Sopenharmony_ci 189bf215546Sopenharmony_ci</protocol> 190