1#![allow(unused_imports)]
2#![allow(clippy::all)]
3use super::*;
4use wasm_bindgen::prelude::*;
5#[cfg(web_sys_unstable_apis)]
6#[wasm_bindgen]
7extern "C" {
8 # [wasm_bindgen (extends = :: js_sys :: Object , js_name = VideoFrame , typescript_type = "VideoFrame")]
9 #[derive(Debug, Clone, PartialEq, Eq)]
10 #[doc = "The `VideoFrame` class."]
11 #[doc = ""]
12 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame)"]
13 #[doc = ""]
14 #[doc = "*This API requires the following crate features to be activated: `VideoFrame`*"]
15 #[doc = ""]
16 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
17 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
18 pub type VideoFrame;
19 #[cfg(web_sys_unstable_apis)]
20 #[cfg(feature = "VideoPixelFormat")]
21 # [wasm_bindgen (structural , method , getter , js_class = "VideoFrame" , js_name = format)]
22 #[doc = "Getter for the `format` field of this object."]
23 #[doc = ""]
24 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/format)"]
25 #[doc = ""]
26 #[doc = "*This API requires the following crate features to be activated: `VideoFrame`, `VideoPixelFormat`*"]
27 #[doc = ""]
28 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
29 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
30 pub fn format(this: &VideoFrame) -> Option<VideoPixelFormat>;
31 #[cfg(web_sys_unstable_apis)]
32 # [wasm_bindgen (structural , method , getter , js_class = "VideoFrame" , js_name = codedWidth)]
33 #[doc = "Getter for the `codedWidth` field of this object."]
34 #[doc = ""]
35 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/codedWidth)"]
36 #[doc = ""]
37 #[doc = "*This API requires the following crate features to be activated: `VideoFrame`*"]
38 #[doc = ""]
39 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
40 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
41 pub fn coded_width(this: &VideoFrame) -> u32;
42 #[cfg(web_sys_unstable_apis)]
43 # [wasm_bindgen (structural , method , getter , js_class = "VideoFrame" , js_name = codedHeight)]
44 #[doc = "Getter for the `codedHeight` field of this object."]
45 #[doc = ""]
46 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/codedHeight)"]
47 #[doc = ""]
48 #[doc = "*This API requires the following crate features to be activated: `VideoFrame`*"]
49 #[doc = ""]
50 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
51 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
52 pub fn coded_height(this: &VideoFrame) -> u32;
53 #[cfg(web_sys_unstable_apis)]
54 #[cfg(feature = "DomRectReadOnly")]
55 # [wasm_bindgen (structural , method , getter , js_class = "VideoFrame" , js_name = codedRect)]
56 #[doc = "Getter for the `codedRect` field of this object."]
57 #[doc = ""]
58 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/codedRect)"]
59 #[doc = ""]
60 #[doc = "*This API requires the following crate features to be activated: `DomRectReadOnly`, `VideoFrame`*"]
61 #[doc = ""]
62 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
63 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
64 pub fn coded_rect(this: &VideoFrame) -> Option<DomRectReadOnly>;
65 #[cfg(web_sys_unstable_apis)]
66 #[cfg(feature = "DomRectReadOnly")]
67 # [wasm_bindgen (structural , method , getter , js_class = "VideoFrame" , js_name = visibleRect)]
68 #[doc = "Getter for the `visibleRect` field of this object."]
69 #[doc = ""]
70 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/visibleRect)"]
71 #[doc = ""]
72 #[doc = "*This API requires the following crate features to be activated: `DomRectReadOnly`, `VideoFrame`*"]
73 #[doc = ""]
74 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
75 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
76 pub fn visible_rect(this: &VideoFrame) -> Option<DomRectReadOnly>;
77 #[cfg(web_sys_unstable_apis)]
78 # [wasm_bindgen (structural , method , getter , js_class = "VideoFrame" , js_name = displayWidth)]
79 #[doc = "Getter for the `displayWidth` field of this object."]
80 #[doc = ""]
81 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/displayWidth)"]
82 #[doc = ""]
83 #[doc = "*This API requires the following crate features to be activated: `VideoFrame`*"]
84 #[doc = ""]
85 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
86 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
87 pub fn display_width(this: &VideoFrame) -> u32;
88 #[cfg(web_sys_unstable_apis)]
89 # [wasm_bindgen (structural , method , getter , js_class = "VideoFrame" , js_name = displayHeight)]
90 #[doc = "Getter for the `displayHeight` field of this object."]
91 #[doc = ""]
92 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/displayHeight)"]
93 #[doc = ""]
94 #[doc = "*This API requires the following crate features to be activated: `VideoFrame`*"]
95 #[doc = ""]
96 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
97 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
98 pub fn display_height(this: &VideoFrame) -> u32;
99 #[cfg(web_sys_unstable_apis)]
100 # [wasm_bindgen (structural , method , getter , js_class = "VideoFrame" , js_name = duration)]
101 #[doc = "Getter for the `duration` field of this object."]
102 #[doc = ""]
103 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/duration)"]
104 #[doc = ""]
105 #[doc = "*This API requires the following crate features to be activated: `VideoFrame`*"]
106 #[doc = ""]
107 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
108 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
109 pub fn duration(this: &VideoFrame) -> Option<f64>;
110 #[cfg(web_sys_unstable_apis)]
111 # [wasm_bindgen (structural , method , getter , js_class = "VideoFrame" , js_name = timestamp)]
112 #[doc = "Getter for the `timestamp` field of this object."]
113 #[doc = ""]
114 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/timestamp)"]
115 #[doc = ""]
116 #[doc = "*This API requires the following crate features to be activated: `VideoFrame`*"]
117 #[doc = ""]
118 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
119 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
120 pub fn timestamp(this: &VideoFrame) -> Option<f64>;
121 #[cfg(web_sys_unstable_apis)]
122 #[cfg(feature = "VideoColorSpace")]
123 # [wasm_bindgen (structural , method , getter , js_class = "VideoFrame" , js_name = colorSpace)]
124 #[doc = "Getter for the `colorSpace` field of this object."]
125 #[doc = ""]
126 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/colorSpace)"]
127 #[doc = ""]
128 #[doc = "*This API requires the following crate features to be activated: `VideoColorSpace`, `VideoFrame`*"]
129 #[doc = ""]
130 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
131 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
132 pub fn color_space(this: &VideoFrame) -> VideoColorSpace;
133 #[cfg(web_sys_unstable_apis)]
134 #[cfg(feature = "HtmlImageElement")]
135 #[wasm_bindgen(catch, constructor, js_class = "VideoFrame")]
136 #[doc = "The `new VideoFrame(..)` constructor, creating a new instance of `VideoFrame`."]
137 #[doc = ""]
138 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/VideoFrame)"]
139 #[doc = ""]
140 #[doc = "*This API requires the following crate features to be activated: `HtmlImageElement`, `VideoFrame`*"]
141 #[doc = ""]
142 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
143 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
144 pub fn new_with_html_image_element(image: &HtmlImageElement) -> Result<VideoFrame, JsValue>;
145 #[cfg(web_sys_unstable_apis)]
146 #[cfg(feature = "SvgImageElement")]
147 #[wasm_bindgen(catch, constructor, js_class = "VideoFrame")]
148 #[doc = "The `new VideoFrame(..)` constructor, creating a new instance of `VideoFrame`."]
149 #[doc = ""]
150 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/VideoFrame)"]
151 #[doc = ""]
152 #[doc = "*This API requires the following crate features to be activated: `SvgImageElement`, `VideoFrame`*"]
153 #[doc = ""]
154 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
155 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
156 pub fn new_with_svg_image_element(image: &SvgImageElement) -> Result<VideoFrame, JsValue>;
157 #[cfg(web_sys_unstable_apis)]
158 #[cfg(feature = "HtmlCanvasElement")]
159 #[wasm_bindgen(catch, constructor, js_class = "VideoFrame")]
160 #[doc = "The `new VideoFrame(..)` constructor, creating a new instance of `VideoFrame`."]
161 #[doc = ""]
162 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/VideoFrame)"]
163 #[doc = ""]
164 #[doc = "*This API requires the following crate features to be activated: `HtmlCanvasElement`, `VideoFrame`*"]
165 #[doc = ""]
166 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
167 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
168 pub fn new_with_html_canvas_element(image: &HtmlCanvasElement) -> Result<VideoFrame, JsValue>;
169 #[cfg(web_sys_unstable_apis)]
170 #[cfg(feature = "HtmlVideoElement")]
171 #[wasm_bindgen(catch, constructor, js_class = "VideoFrame")]
172 #[doc = "The `new VideoFrame(..)` constructor, creating a new instance of `VideoFrame`."]
173 #[doc = ""]
174 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/VideoFrame)"]
175 #[doc = ""]
176 #[doc = "*This API requires the following crate features to be activated: `HtmlVideoElement`, `VideoFrame`*"]
177 #[doc = ""]
178 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
179 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
180 pub fn new_with_html_video_element(image: &HtmlVideoElement) -> Result<VideoFrame, JsValue>;
181 #[cfg(web_sys_unstable_apis)]
182 #[cfg(feature = "ImageBitmap")]
183 #[wasm_bindgen(catch, constructor, js_class = "VideoFrame")]
184 #[doc = "The `new VideoFrame(..)` constructor, creating a new instance of `VideoFrame`."]
185 #[doc = ""]
186 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/VideoFrame)"]
187 #[doc = ""]
188 #[doc = "*This API requires the following crate features to be activated: `ImageBitmap`, `VideoFrame`*"]
189 #[doc = ""]
190 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
191 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
192 pub fn new_with_image_bitmap(image: &ImageBitmap) -> Result<VideoFrame, JsValue>;
193 #[cfg(web_sys_unstable_apis)]
194 #[cfg(feature = "OffscreenCanvas")]
195 #[wasm_bindgen(catch, constructor, js_class = "VideoFrame")]
196 #[doc = "The `new VideoFrame(..)` constructor, creating a new instance of `VideoFrame`."]
197 #[doc = ""]
198 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/VideoFrame)"]
199 #[doc = ""]
200 #[doc = "*This API requires the following crate features to be activated: `OffscreenCanvas`, `VideoFrame`*"]
201 #[doc = ""]
202 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
203 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
204 pub fn new_with_offscreen_canvas(image: &OffscreenCanvas) -> Result<VideoFrame, JsValue>;
205 #[cfg(web_sys_unstable_apis)]
206 #[wasm_bindgen(catch, constructor, js_class = "VideoFrame")]
207 #[doc = "The `new VideoFrame(..)` constructor, creating a new instance of `VideoFrame`."]
208 #[doc = ""]
209 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/VideoFrame)"]
210 #[doc = ""]
211 #[doc = "*This API requires the following crate features to be activated: `VideoFrame`*"]
212 #[doc = ""]
213 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
214 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
215 pub fn new_with_video_frame(image: &VideoFrame) -> Result<VideoFrame, JsValue>;
216 #[cfg(web_sys_unstable_apis)]
217 #[cfg(all(feature = "HtmlImageElement", feature = "VideoFrameInit",))]
218 #[wasm_bindgen(catch, constructor, js_class = "VideoFrame")]
219 #[doc = "The `new VideoFrame(..)` constructor, creating a new instance of `VideoFrame`."]
220 #[doc = ""]
221 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/VideoFrame)"]
222 #[doc = ""]
223 #[doc = "*This API requires the following crate features to be activated: `HtmlImageElement`, `VideoFrame`, `VideoFrameInit`*"]
224 #[doc = ""]
225 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
226 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
227 pub fn new_with_html_image_element_and_video_frame_init(
228 image: &HtmlImageElement,
229 init: &VideoFrameInit,
230 ) -> Result<VideoFrame, JsValue>;
231 #[cfg(web_sys_unstable_apis)]
232 #[cfg(all(feature = "SvgImageElement", feature = "VideoFrameInit",))]
233 #[wasm_bindgen(catch, constructor, js_class = "VideoFrame")]
234 #[doc = "The `new VideoFrame(..)` constructor, creating a new instance of `VideoFrame`."]
235 #[doc = ""]
236 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/VideoFrame)"]
237 #[doc = ""]
238 #[doc = "*This API requires the following crate features to be activated: `SvgImageElement`, `VideoFrame`, `VideoFrameInit`*"]
239 #[doc = ""]
240 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
241 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
242 pub fn new_with_svg_image_element_and_video_frame_init(
243 image: &SvgImageElement,
244 init: &VideoFrameInit,
245 ) -> Result<VideoFrame, JsValue>;
246 #[cfg(web_sys_unstable_apis)]
247 #[cfg(all(feature = "HtmlCanvasElement", feature = "VideoFrameInit",))]
248 #[wasm_bindgen(catch, constructor, js_class = "VideoFrame")]
249 #[doc = "The `new VideoFrame(..)` constructor, creating a new instance of `VideoFrame`."]
250 #[doc = ""]
251 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/VideoFrame)"]
252 #[doc = ""]
253 #[doc = "*This API requires the following crate features to be activated: `HtmlCanvasElement`, `VideoFrame`, `VideoFrameInit`*"]
254 #[doc = ""]
255 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
256 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
257 pub fn new_with_html_canvas_element_and_video_frame_init(
258 image: &HtmlCanvasElement,
259 init: &VideoFrameInit,
260 ) -> Result<VideoFrame, JsValue>;
261 #[cfg(web_sys_unstable_apis)]
262 #[cfg(all(feature = "HtmlVideoElement", feature = "VideoFrameInit",))]
263 #[wasm_bindgen(catch, constructor, js_class = "VideoFrame")]
264 #[doc = "The `new VideoFrame(..)` constructor, creating a new instance of `VideoFrame`."]
265 #[doc = ""]
266 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/VideoFrame)"]
267 #[doc = ""]
268 #[doc = "*This API requires the following crate features to be activated: `HtmlVideoElement`, `VideoFrame`, `VideoFrameInit`*"]
269 #[doc = ""]
270 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
271 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
272 pub fn new_with_html_video_element_and_video_frame_init(
273 image: &HtmlVideoElement,
274 init: &VideoFrameInit,
275 ) -> Result<VideoFrame, JsValue>;
276 #[cfg(web_sys_unstable_apis)]
277 #[cfg(all(feature = "ImageBitmap", feature = "VideoFrameInit",))]
278 #[wasm_bindgen(catch, constructor, js_class = "VideoFrame")]
279 #[doc = "The `new VideoFrame(..)` constructor, creating a new instance of `VideoFrame`."]
280 #[doc = ""]
281 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/VideoFrame)"]
282 #[doc = ""]
283 #[doc = "*This API requires the following crate features to be activated: `ImageBitmap`, `VideoFrame`, `VideoFrameInit`*"]
284 #[doc = ""]
285 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
286 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
287 pub fn new_with_image_bitmap_and_video_frame_init(
288 image: &ImageBitmap,
289 init: &VideoFrameInit,
290 ) -> Result<VideoFrame, JsValue>;
291 #[cfg(web_sys_unstable_apis)]
292 #[cfg(all(feature = "OffscreenCanvas", feature = "VideoFrameInit",))]
293 #[wasm_bindgen(catch, constructor, js_class = "VideoFrame")]
294 #[doc = "The `new VideoFrame(..)` constructor, creating a new instance of `VideoFrame`."]
295 #[doc = ""]
296 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/VideoFrame)"]
297 #[doc = ""]
298 #[doc = "*This API requires the following crate features to be activated: `OffscreenCanvas`, `VideoFrame`, `VideoFrameInit`*"]
299 #[doc = ""]
300 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
301 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
302 pub fn new_with_offscreen_canvas_and_video_frame_init(
303 image: &OffscreenCanvas,
304 init: &VideoFrameInit,
305 ) -> Result<VideoFrame, JsValue>;
306 #[cfg(web_sys_unstable_apis)]
307 #[cfg(feature = "VideoFrameInit")]
308 #[wasm_bindgen(catch, constructor, js_class = "VideoFrame")]
309 #[doc = "The `new VideoFrame(..)` constructor, creating a new instance of `VideoFrame`."]
310 #[doc = ""]
311 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/VideoFrame)"]
312 #[doc = ""]
313 #[doc = "*This API requires the following crate features to be activated: `VideoFrame`, `VideoFrameInit`*"]
314 #[doc = ""]
315 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
316 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
317 pub fn new_with_video_frame_and_video_frame_init(
318 image: &VideoFrame,
319 init: &VideoFrameInit,
320 ) -> Result<VideoFrame, JsValue>;
321 #[cfg(web_sys_unstable_apis)]
322 #[cfg(feature = "VideoFrameBufferInit")]
323 #[wasm_bindgen(catch, constructor, js_class = "VideoFrame")]
324 #[doc = "The `new VideoFrame(..)` constructor, creating a new instance of `VideoFrame`."]
325 #[doc = ""]
326 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/VideoFrame)"]
327 #[doc = ""]
328 #[doc = "*This API requires the following crate features to be activated: `VideoFrame`, `VideoFrameBufferInit`*"]
329 #[doc = ""]
330 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
331 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
332 pub fn new_with_buffer_source_and_video_frame_buffer_init(
333 data: &::js_sys::Object,
334 init: &VideoFrameBufferInit,
335 ) -> Result<VideoFrame, JsValue>;
336 #[cfg(web_sys_unstable_apis)]
337 #[cfg(feature = "VideoFrameBufferInit")]
338 #[wasm_bindgen(catch, constructor, js_class = "VideoFrame")]
339 #[doc = "The `new VideoFrame(..)` constructor, creating a new instance of `VideoFrame`."]
340 #[doc = ""]
341 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/VideoFrame)"]
342 #[doc = ""]
343 #[doc = "*This API requires the following crate features to be activated: `VideoFrame`, `VideoFrameBufferInit`*"]
344 #[doc = ""]
345 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
346 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
347 pub fn new_with_u8_array_and_video_frame_buffer_init(
348 data: &mut [u8],
349 init: &VideoFrameBufferInit,
350 ) -> Result<VideoFrame, JsValue>;
351 #[cfg(web_sys_unstable_apis)]
352 # [wasm_bindgen (method , structural , js_class = "VideoFrame" , js_name = allocationSize)]
353 #[doc = "The `allocationSize()` method."]
354 #[doc = ""]
355 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/allocationSize)"]
356 #[doc = ""]
357 #[doc = "*This API requires the following crate features to be activated: `VideoFrame`*"]
358 #[doc = ""]
359 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
360 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
361 pub fn allocation_size(this: &VideoFrame) -> u32;
362 #[cfg(web_sys_unstable_apis)]
363 #[cfg(feature = "VideoFrameCopyToOptions")]
364 # [wasm_bindgen (method , structural , js_class = "VideoFrame" , js_name = allocationSize)]
365 #[doc = "The `allocationSize()` method."]
366 #[doc = ""]
367 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/allocationSize)"]
368 #[doc = ""]
369 #[doc = "*This API requires the following crate features to be activated: `VideoFrame`, `VideoFrameCopyToOptions`*"]
370 #[doc = ""]
371 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
372 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
373 pub fn allocation_size_with_options(
374 this: &VideoFrame,
375 options: &VideoFrameCopyToOptions,
376 ) -> u32;
377 #[cfg(web_sys_unstable_apis)]
378 # [wasm_bindgen (method , structural , js_class = "VideoFrame" , js_name = clone)]
379 #[doc = "The `clone()` method."]
380 #[doc = ""]
381 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/clone)"]
382 #[doc = ""]
383 #[doc = "*This API requires the following crate features to be activated: `VideoFrame`*"]
384 #[doc = ""]
385 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
386 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
387 pub fn clone(this: &VideoFrame) -> VideoFrame;
388 #[cfg(web_sys_unstable_apis)]
389 # [wasm_bindgen (method , structural , js_class = "VideoFrame" , js_name = close)]
390 #[doc = "The `close()` method."]
391 #[doc = ""]
392 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/close)"]
393 #[doc = ""]
394 #[doc = "*This API requires the following crate features to be activated: `VideoFrame`*"]
395 #[doc = ""]
396 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
397 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
398 pub fn close(this: &VideoFrame);
399 #[cfg(web_sys_unstable_apis)]
400 # [wasm_bindgen (method , structural , js_class = "VideoFrame" , js_name = copyTo)]
401 #[doc = "The `copyTo()` method."]
402 #[doc = ""]
403 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/copyTo)"]
404 #[doc = ""]
405 #[doc = "*This API requires the following crate features to be activated: `VideoFrame`*"]
406 #[doc = ""]
407 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
408 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
409 pub fn copy_to_with_buffer_source(
410 this: &VideoFrame,
411 destination: &::js_sys::Object,
412 ) -> ::js_sys::Promise;
413 #[cfg(web_sys_unstable_apis)]
414 # [wasm_bindgen (method , structural , js_class = "VideoFrame" , js_name = copyTo)]
415 #[doc = "The `copyTo()` method."]
416 #[doc = ""]
417 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/copyTo)"]
418 #[doc = ""]
419 #[doc = "*This API requires the following crate features to be activated: `VideoFrame`*"]
420 #[doc = ""]
421 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
422 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
423 pub fn copy_to_with_u8_array(this: &VideoFrame, destination: &mut [u8]) -> ::js_sys::Promise;
424 #[cfg(web_sys_unstable_apis)]
425 #[cfg(feature = "VideoFrameCopyToOptions")]
426 # [wasm_bindgen (method , structural , js_class = "VideoFrame" , js_name = copyTo)]
427 #[doc = "The `copyTo()` method."]
428 #[doc = ""]
429 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/copyTo)"]
430 #[doc = ""]
431 #[doc = "*This API requires the following crate features to be activated: `VideoFrame`, `VideoFrameCopyToOptions`*"]
432 #[doc = ""]
433 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
434 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
435 pub fn copy_to_with_buffer_source_and_options(
436 this: &VideoFrame,
437 destination: &::js_sys::Object,
438 options: &VideoFrameCopyToOptions,
439 ) -> ::js_sys::Promise;
440 #[cfg(web_sys_unstable_apis)]
441 #[cfg(feature = "VideoFrameCopyToOptions")]
442 # [wasm_bindgen (method , structural , js_class = "VideoFrame" , js_name = copyTo)]
443 #[doc = "The `copyTo()` method."]
444 #[doc = ""]
445 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/VideoFrame/copyTo)"]
446 #[doc = ""]
447 #[doc = "*This API requires the following crate features to be activated: `VideoFrame`, `VideoFrameCopyToOptions`*"]
448 #[doc = ""]
449 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
450 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
451 pub fn copy_to_with_u8_array_and_options(
452 this: &VideoFrame,
453 destination: &mut [u8],
454 options: &VideoFrameCopyToOptions,
455 ) -> ::js_sys::Promise;
456}
457