]>
git.proxmox.com Git - rustc.git/blob - vendor/web-sys/src/features/gen_ImageCapture.rs
1 #![allow(unused_imports)]
4 use wasm_bindgen
::prelude
::*;
5 #[cfg(web_sys_unstable_apis)]
8 # [wasm_bindgen (extends = :: js_sys :: Object , js_name = ImageCapture , typescript_type = "ImageCapture")]
9 #[derive(Debug, Clone, PartialEq, Eq)]
10 #[doc = "The `ImageCapture` class."]
12 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/ImageCapture)"]
14 #[doc = "*This API requires the following crate features to be activated: `ImageCapture`*"]
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 ImageCapture
;
19 #[cfg(web_sys_unstable_apis)]
20 #[cfg(feature = "MediaStreamTrack")]
21 # [wasm_bindgen (structural , method , getter , js_class = "ImageCapture" , js_name = track)]
22 #[doc = "Getter for the `track` field of this object."]
24 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/ImageCapture/track)"]
26 #[doc = "*This API requires the following crate features to be activated: `ImageCapture`, `MediaStreamTrack`*"]
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 track(this
: &ImageCapture
) -> MediaStreamTrack
;
31 #[cfg(web_sys_unstable_apis)]
32 #[cfg(feature = "MediaStreamTrack")]
33 #[wasm_bindgen(catch, constructor, js_class = "ImageCapture")]
34 #[doc = "The `new ImageCapture(..)` constructor, creating a new instance of `ImageCapture`."]
36 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/ImageCapture/ImageCapture)"]
38 #[doc = "*This API requires the following crate features to be activated: `ImageCapture`, `MediaStreamTrack`*"]
40 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
41 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
42 pub fn new(video_track
: &MediaStreamTrack
) -> Result
<ImageCapture
, JsValue
>;
43 #[cfg(web_sys_unstable_apis)]
44 # [wasm_bindgen (method , structural , js_class = "ImageCapture" , js_name = getPhotoCapabilities)]
45 #[doc = "The `getPhotoCapabilities()` method."]
47 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/ImageCapture/getPhotoCapabilities)"]
49 #[doc = "*This API requires the following crate features to be activated: `ImageCapture`*"]
51 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
52 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
53 pub fn get_photo_capabilities(this
: &ImageCapture
) -> ::js_sys
::Promise
;
54 #[cfg(web_sys_unstable_apis)]
55 # [wasm_bindgen (method , structural , js_class = "ImageCapture" , js_name = getPhotoSettings)]
56 #[doc = "The `getPhotoSettings()` method."]
58 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/ImageCapture/getPhotoSettings)"]
60 #[doc = "*This API requires the following crate features to be activated: `ImageCapture`*"]
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 get_photo_settings(this
: &ImageCapture
) -> ::js_sys
::Promise
;
65 #[cfg(web_sys_unstable_apis)]
66 # [wasm_bindgen (method , structural , js_class = "ImageCapture" , js_name = grabFrame)]
67 #[doc = "The `grabFrame()` method."]
69 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/ImageCapture/grabFrame)"]
71 #[doc = "*This API requires the following crate features to be activated: `ImageCapture`*"]
73 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
74 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
75 pub fn grab_frame(this
: &ImageCapture
) -> ::js_sys
::Promise
;
76 #[cfg(web_sys_unstable_apis)]
77 # [wasm_bindgen (method , structural , js_class = "ImageCapture" , js_name = takePhoto)]
78 #[doc = "The `takePhoto()` method."]
80 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/ImageCapture/takePhoto)"]
82 #[doc = "*This API requires the following crate features to be activated: `ImageCapture`*"]
84 #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
85 #[doc = "[described in the `wasm-bindgen` guide](https://rustwasm.github.io/docs/wasm-bindgen/web-sys/unstable-apis.html)*"]
86 pub fn take_photo(this
: &ImageCapture
) -> ::js_sys
::Promise
;