|
25 | 25 |
|
26 | 26 | <request name="start"> |
27 | 27 | <description summary="start session"> |
28 | | - Start session and keeps sending frame. |
| 28 | + Start session and keeps sending frame with the given buffer. |
29 | 29 | </description> |
| 30 | + <arg name="buffer" type="object" interface="wl_buffer" allow-null=true summary="buffer to receive frame data, null for export dmabuf"/> |
30 | 31 | </request> |
31 | 32 |
|
32 | 33 | <request name="frame_done"> |
|
41 | 42 | </request> |
42 | 43 |
|
43 | 44 | <event name="frame"> |
| 45 | + <description summary="notify the client a new frame"> |
| 46 | + Notify the client that a new frame is coming, client should copy or import dmabuf. |
| 47 | + </description> |
| 48 | + </event> |
| 49 | + |
| 50 | + <event name="dmabuf_frame"> |
44 | 51 | <description summary="supply the client with information about the frame"> |
45 | | - Main event supplying the client with information about the frame. If the capture didn't fail, this event is always |
46 | | - emitted first before any other events. |
| 52 | + Main event supplying the client with information about the dmabuf frame. |
| 53 | + If the capture didn't fail, this event is directly after the frame event. |
47 | 54 | When mask is provided, x and y should be offset relative to mask surface origin. Otherwise offset_x and offset_y should always |
48 | 55 | be zero. |
49 | 56 | </description> |
|
59 | 66 | <arg name="num_objects" type="uint"/> |
60 | 67 | </event> |
61 | 68 |
|
62 | | - <event name="object"> |
| 69 | + <event name="dmabuf_object"> |
63 | 70 | <description summary="supply the client with object fd"> |
64 | 71 | </description> |
65 | 72 | <arg name="index" type="uint"/> |
|
87 | 94 | </description> |
88 | 95 | <arg name="reason" type="uint" enum="treeland_capture_session_v1.cancel_reason"/> |
89 | 96 | </event> |
90 | | - |
91 | 97 | </interface> |
92 | 98 |
|
93 | 99 | <interface name="treeland_capture_frame_v1" version="1"> |
|
100 | 106 | <entry name="y_inverted" value="0x1" summary="contents are y-inverted"/> |
101 | 107 | </enum> |
102 | 108 |
|
103 | | - <event name="buffer"> |
104 | | - <description summary="inform client to prepare buffer"> |
105 | | - Inform client to prepare buffer. |
106 | | - </description> |
107 | | - <arg name="format" type="uint" enum="wl_shm.format"/> |
108 | | - <arg name="width" type="uint"/> |
109 | | - <arg name="height" type="uint"/> |
110 | | - <arg name="stride" type="uint"/> |
111 | | - </event> |
112 | | - |
113 | | - <event name="buffer_done"> |
114 | | - <description summary="all buffer formats have done"> |
115 | | - Inform client that all buffer formats supported are emitted. |
116 | | - </description> |
117 | | - </event> |
118 | | - |
119 | 109 | <request name="copy"> |
120 | 110 | <description summary="copy capture contents"> |
121 | 111 | Copy capture contents to provided buffer |
|
190 | 180 | <arg name="source_type" type="uint" enum="source_type" summary="final capture source type"/> |
191 | 181 | </event> |
192 | 182 |
|
| 183 | + <event name="source_shm_buffer"> |
| 184 | + <description summary="notify client the supported shm buffer format"> |
| 185 | + This event notify the client what kind of shm buffer is supported. It may be sent several times after "source_ready". |
| 186 | + If client receives dmabuf notification, it should use dmabuf instead. |
| 187 | + </description> |
| 188 | + <arg name="format" type="uint" enum="wl_shm.format" summary="shm buffer format"/> |
| 189 | + <arg name="width" type="uint" summary="shm buffer width"/> |
| 190 | + <arg name="height" type="uint" summary="shm buffer height"/> |
| 191 | + <arg name="stride" type="uint" summary="shm buffer stride"/> |
| 192 | + </event> |
| 193 | + |
| 194 | + <event name="source_dmabuf"> |
| 195 | + <description summary="notify client the supported dmabuf format"> |
| 196 | + This event notify the client what kind of dmabuf is supported. It may be sent several times after "source_ready". |
| 197 | + If client receives the notification, it should use dmabuf instead of shm buffer. |
| 198 | + </description> |
| 199 | + <arg name="format" type="uint" summary="fourcc pixel format"/> |
| 200 | + <arg name="width" type="uint" summary="dmabuf width"/> |
| 201 | + <arg name="height" type="uint" summary="dmabuf height"/> |
| 202 | + </event> |
| 203 | + |
| 204 | + <event name="source_export_dmabuf"> |
| 205 | + <description summary="notify client that compositor supports export dmabuf"> |
| 206 | + This event notify the client that compositor supports export dmabuf. It should be sent just once |
| 207 | + after "source_ready". Client should prefer export dmabuf over dmabuf or shm buffer. |
| 208 | + </description> |
| 209 | + </event> |
| 210 | + |
| 211 | + <event name="source_buffer_done"> |
| 212 | + <description summary="notify client that all supported buffer formats are sent"> |
| 213 | + This event indicates an end of source_shm_buffer, source_dmabuf and source_export_dmabuf event |
| 214 | + sequence. |
| 215 | + </description> |
| 216 | + </event> |
| 217 | + |
193 | 218 | <event name="source_failed"> |
194 | 219 | <description summary="notify client that source selection is failed"> |
195 | 220 | There could a lot of reasons but the most common one is that selector is busy |
|
0 commit comments