Skip to main content

web_sys/features/
gen_MediaTrackConstraints.rs

1#![allow(unused_imports)]
2#![allow(clippy::all)]
3use super::*;
4use wasm_bindgen::prelude::*;
5#[wasm_bindgen]
6extern "C" {
7    # [wasm_bindgen (extends = :: js_sys :: Object , js_name = MediaTrackConstraints)]
8    #[derive(Debug, Clone, PartialEq, Eq)]
9    #[doc = "The `MediaTrackConstraints` dictionary."]
10    #[doc = ""]
11    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
12    pub type MediaTrackConstraints;
13    #[doc = "Get the `autoGainControl` field of this object."]
14    #[doc = ""]
15    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
16    #[wasm_bindgen(method, getter = "autoGainControl")]
17    pub fn get_auto_gain_control(this: &MediaTrackConstraints) -> ::wasm_bindgen::JsValue;
18    #[doc = "Change the `autoGainControl` field of this object."]
19    #[doc = ""]
20    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
21    #[wasm_bindgen(method, setter = "autoGainControl")]
22    pub fn set_auto_gain_control(this: &MediaTrackConstraints, val: &::wasm_bindgen::JsValue);
23    #[doc = "Change the `autoGainControl` field of this object."]
24    #[doc = ""]
25    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
26    #[wasm_bindgen(method, setter = "autoGainControl")]
27    pub fn set_auto_gain_control_bool(this: &MediaTrackConstraints, val: bool);
28    #[cfg(feature = "ConstrainBooleanParameters")]
29    #[doc = "Change the `autoGainControl` field of this object."]
30    #[doc = ""]
31    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
32    #[wasm_bindgen(method, setter = "autoGainControl")]
33    pub fn set_auto_gain_control_constrain_boolean_parameters(
34        this: &MediaTrackConstraints,
35        val: &ConstrainBooleanParameters,
36    );
37    #[doc = "Get the `browserWindow` field of this object."]
38    #[doc = ""]
39    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
40    #[wasm_bindgen(method, getter = "browserWindow")]
41    pub fn get_browser_window(this: &MediaTrackConstraints) -> Option<f64>;
42    #[doc = "Change the `browserWindow` field of this object."]
43    #[doc = ""]
44    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
45    #[wasm_bindgen(method, setter = "browserWindow")]
46    pub fn set_browser_window(this: &MediaTrackConstraints, val: f64);
47    #[doc = "Change the `browserWindow` field of this object."]
48    #[doc = ""]
49    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
50    #[wasm_bindgen(method, setter = "browserWindow")]
51    pub fn set_browser_window_i32(this: &MediaTrackConstraints, val: i32);
52    #[doc = "Change the `browserWindow` field of this object."]
53    #[doc = ""]
54    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
55    #[wasm_bindgen(method, setter = "browserWindow")]
56    pub fn set_browser_window_f64(this: &MediaTrackConstraints, val: f64);
57    #[doc = "Get the `channelCount` field of this object."]
58    #[doc = ""]
59    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
60    #[wasm_bindgen(method, getter = "channelCount")]
61    pub fn get_channel_count(this: &MediaTrackConstraints) -> ::wasm_bindgen::JsValue;
62    #[doc = "Change the `channelCount` field of this object."]
63    #[doc = ""]
64    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
65    #[wasm_bindgen(method, setter = "channelCount")]
66    pub fn set_channel_count(this: &MediaTrackConstraints, val: &::wasm_bindgen::JsValue);
67    #[doc = "Change the `channelCount` field of this object."]
68    #[doc = ""]
69    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
70    #[wasm_bindgen(method, setter = "channelCount")]
71    pub fn set_channel_count_i32(this: &MediaTrackConstraints, val: i32);
72    #[cfg(feature = "ConstrainLongRange")]
73    #[doc = "Change the `channelCount` field of this object."]
74    #[doc = ""]
75    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
76    #[wasm_bindgen(method, setter = "channelCount")]
77    pub fn set_channel_count_constrain_long_range(
78        this: &MediaTrackConstraints,
79        val: &ConstrainLongRange,
80    );
81    #[doc = "Get the `deviceId` field of this object."]
82    #[doc = ""]
83    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
84    #[wasm_bindgen(method, getter = "deviceId")]
85    pub fn get_device_id(this: &MediaTrackConstraints) -> ::wasm_bindgen::JsValue;
86    #[doc = "Change the `deviceId` field of this object."]
87    #[doc = ""]
88    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
89    #[wasm_bindgen(method, setter = "deviceId")]
90    pub fn set_device_id(this: &MediaTrackConstraints, val: &::wasm_bindgen::JsValue);
91    #[doc = "Change the `deviceId` field of this object."]
92    #[doc = ""]
93    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
94    #[wasm_bindgen(method, setter = "deviceId")]
95    pub fn set_device_id_str(this: &MediaTrackConstraints, val: &str);
96    #[doc = "Change the `deviceId` field of this object."]
97    #[doc = ""]
98    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
99    #[wasm_bindgen(method, setter = "deviceId")]
100    pub fn set_device_id_str_sequence(this: &MediaTrackConstraints, val: &::wasm_bindgen::JsValue);
101    #[cfg(feature = "ConstrainDomStringParameters")]
102    #[doc = "Change the `deviceId` field of this object."]
103    #[doc = ""]
104    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
105    #[wasm_bindgen(method, setter = "deviceId")]
106    pub fn set_device_id_constrain_dom_string_parameters(
107        this: &MediaTrackConstraints,
108        val: &ConstrainDomStringParameters,
109    );
110    #[doc = "Get the `echoCancellation` field of this object."]
111    #[doc = ""]
112    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
113    #[wasm_bindgen(method, getter = "echoCancellation")]
114    pub fn get_echo_cancellation(this: &MediaTrackConstraints) -> ::wasm_bindgen::JsValue;
115    #[doc = "Change the `echoCancellation` field of this object."]
116    #[doc = ""]
117    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
118    #[wasm_bindgen(method, setter = "echoCancellation")]
119    pub fn set_echo_cancellation(this: &MediaTrackConstraints, val: &::wasm_bindgen::JsValue);
120    #[doc = "Change the `echoCancellation` field of this object."]
121    #[doc = ""]
122    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
123    #[wasm_bindgen(method, setter = "echoCancellation")]
124    pub fn set_echo_cancellation_bool(this: &MediaTrackConstraints, val: bool);
125    #[cfg(feature = "ConstrainBooleanParameters")]
126    #[doc = "Change the `echoCancellation` field of this object."]
127    #[doc = ""]
128    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
129    #[wasm_bindgen(method, setter = "echoCancellation")]
130    pub fn set_echo_cancellation_constrain_boolean_parameters(
131        this: &MediaTrackConstraints,
132        val: &ConstrainBooleanParameters,
133    );
134    #[doc = "Get the `facingMode` field of this object."]
135    #[doc = ""]
136    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
137    #[wasm_bindgen(method, getter = "facingMode")]
138    pub fn get_facing_mode(this: &MediaTrackConstraints) -> ::wasm_bindgen::JsValue;
139    #[doc = "Change the `facingMode` field of this object."]
140    #[doc = ""]
141    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
142    #[wasm_bindgen(method, setter = "facingMode")]
143    pub fn set_facing_mode(this: &MediaTrackConstraints, val: &::wasm_bindgen::JsValue);
144    #[doc = "Change the `facingMode` field of this object."]
145    #[doc = ""]
146    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
147    #[wasm_bindgen(method, setter = "facingMode")]
148    pub fn set_facing_mode_str(this: &MediaTrackConstraints, val: &str);
149    #[doc = "Change the `facingMode` field of this object."]
150    #[doc = ""]
151    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
152    #[wasm_bindgen(method, setter = "facingMode")]
153    pub fn set_facing_mode_str_sequence(
154        this: &MediaTrackConstraints,
155        val: &::wasm_bindgen::JsValue,
156    );
157    #[cfg(feature = "ConstrainDomStringParameters")]
158    #[doc = "Change the `facingMode` field of this object."]
159    #[doc = ""]
160    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
161    #[wasm_bindgen(method, setter = "facingMode")]
162    pub fn set_facing_mode_constrain_dom_string_parameters(
163        this: &MediaTrackConstraints,
164        val: &ConstrainDomStringParameters,
165    );
166    #[doc = "Get the `frameRate` field of this object."]
167    #[doc = ""]
168    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
169    #[wasm_bindgen(method, getter = "frameRate")]
170    pub fn get_frame_rate(this: &MediaTrackConstraints) -> ::wasm_bindgen::JsValue;
171    #[doc = "Change the `frameRate` field of this object."]
172    #[doc = ""]
173    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
174    #[wasm_bindgen(method, setter = "frameRate")]
175    pub fn set_frame_rate(this: &MediaTrackConstraints, val: &::wasm_bindgen::JsValue);
176    #[doc = "Change the `frameRate` field of this object."]
177    #[doc = ""]
178    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
179    #[wasm_bindgen(method, setter = "frameRate")]
180    pub fn set_frame_rate_f64(this: &MediaTrackConstraints, val: f64);
181    #[cfg(feature = "ConstrainDoubleRange")]
182    #[doc = "Change the `frameRate` field of this object."]
183    #[doc = ""]
184    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
185    #[wasm_bindgen(method, setter = "frameRate")]
186    pub fn set_frame_rate_constrain_double_range(
187        this: &MediaTrackConstraints,
188        val: &ConstrainDoubleRange,
189    );
190    #[doc = "Get the `height` field of this object."]
191    #[doc = ""]
192    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
193    #[wasm_bindgen(method, getter = "height")]
194    pub fn get_height(this: &MediaTrackConstraints) -> ::wasm_bindgen::JsValue;
195    #[doc = "Change the `height` field of this object."]
196    #[doc = ""]
197    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
198    #[wasm_bindgen(method, setter = "height")]
199    pub fn set_height(this: &MediaTrackConstraints, val: &::wasm_bindgen::JsValue);
200    #[doc = "Change the `height` field of this object."]
201    #[doc = ""]
202    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
203    #[wasm_bindgen(method, setter = "height")]
204    pub fn set_height_i32(this: &MediaTrackConstraints, val: i32);
205    #[cfg(feature = "ConstrainLongRange")]
206    #[doc = "Change the `height` field of this object."]
207    #[doc = ""]
208    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
209    #[wasm_bindgen(method, setter = "height")]
210    pub fn set_height_constrain_long_range(this: &MediaTrackConstraints, val: &ConstrainLongRange);
211    #[doc = "Get the `mediaSource` field of this object."]
212    #[doc = ""]
213    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
214    #[wasm_bindgen(method, getter = "mediaSource")]
215    pub fn get_media_source(this: &MediaTrackConstraints) -> Option<::alloc::string::String>;
216    #[doc = "Change the `mediaSource` field of this object."]
217    #[doc = ""]
218    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
219    #[wasm_bindgen(method, setter = "mediaSource")]
220    pub fn set_media_source(this: &MediaTrackConstraints, val: &str);
221    #[doc = "Get the `noiseSuppression` field of this object."]
222    #[doc = ""]
223    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
224    #[wasm_bindgen(method, getter = "noiseSuppression")]
225    pub fn get_noise_suppression(this: &MediaTrackConstraints) -> ::wasm_bindgen::JsValue;
226    #[doc = "Change the `noiseSuppression` field of this object."]
227    #[doc = ""]
228    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
229    #[wasm_bindgen(method, setter = "noiseSuppression")]
230    pub fn set_noise_suppression(this: &MediaTrackConstraints, val: &::wasm_bindgen::JsValue);
231    #[doc = "Change the `noiseSuppression` field of this object."]
232    #[doc = ""]
233    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
234    #[wasm_bindgen(method, setter = "noiseSuppression")]
235    pub fn set_noise_suppression_bool(this: &MediaTrackConstraints, val: bool);
236    #[cfg(feature = "ConstrainBooleanParameters")]
237    #[doc = "Change the `noiseSuppression` field of this object."]
238    #[doc = ""]
239    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
240    #[wasm_bindgen(method, setter = "noiseSuppression")]
241    pub fn set_noise_suppression_constrain_boolean_parameters(
242        this: &MediaTrackConstraints,
243        val: &ConstrainBooleanParameters,
244    );
245    #[doc = "Get the `scrollWithPage` field of this object."]
246    #[doc = ""]
247    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
248    #[wasm_bindgen(method, getter = "scrollWithPage")]
249    pub fn get_scroll_with_page(this: &MediaTrackConstraints) -> Option<bool>;
250    #[doc = "Change the `scrollWithPage` field of this object."]
251    #[doc = ""]
252    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
253    #[wasm_bindgen(method, setter = "scrollWithPage")]
254    pub fn set_scroll_with_page(this: &MediaTrackConstraints, val: bool);
255    #[doc = "Get the `viewportHeight` field of this object."]
256    #[doc = ""]
257    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
258    #[wasm_bindgen(method, getter = "viewportHeight")]
259    pub fn get_viewport_height(this: &MediaTrackConstraints) -> ::wasm_bindgen::JsValue;
260    #[doc = "Change the `viewportHeight` field of this object."]
261    #[doc = ""]
262    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
263    #[wasm_bindgen(method, setter = "viewportHeight")]
264    pub fn set_viewport_height(this: &MediaTrackConstraints, val: &::wasm_bindgen::JsValue);
265    #[doc = "Change the `viewportHeight` field of this object."]
266    #[doc = ""]
267    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
268    #[wasm_bindgen(method, setter = "viewportHeight")]
269    pub fn set_viewport_height_i32(this: &MediaTrackConstraints, val: i32);
270    #[cfg(feature = "ConstrainLongRange")]
271    #[doc = "Change the `viewportHeight` field of this object."]
272    #[doc = ""]
273    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
274    #[wasm_bindgen(method, setter = "viewportHeight")]
275    pub fn set_viewport_height_constrain_long_range(
276        this: &MediaTrackConstraints,
277        val: &ConstrainLongRange,
278    );
279    #[doc = "Get the `viewportOffsetX` field of this object."]
280    #[doc = ""]
281    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
282    #[wasm_bindgen(method, getter = "viewportOffsetX")]
283    pub fn get_viewport_offset_x(this: &MediaTrackConstraints) -> ::wasm_bindgen::JsValue;
284    #[doc = "Change the `viewportOffsetX` field of this object."]
285    #[doc = ""]
286    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
287    #[wasm_bindgen(method, setter = "viewportOffsetX")]
288    pub fn set_viewport_offset_x(this: &MediaTrackConstraints, val: &::wasm_bindgen::JsValue);
289    #[doc = "Change the `viewportOffsetX` field of this object."]
290    #[doc = ""]
291    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
292    #[wasm_bindgen(method, setter = "viewportOffsetX")]
293    pub fn set_viewport_offset_x_i32(this: &MediaTrackConstraints, val: i32);
294    #[cfg(feature = "ConstrainLongRange")]
295    #[doc = "Change the `viewportOffsetX` field of this object."]
296    #[doc = ""]
297    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
298    #[wasm_bindgen(method, setter = "viewportOffsetX")]
299    pub fn set_viewport_offset_x_constrain_long_range(
300        this: &MediaTrackConstraints,
301        val: &ConstrainLongRange,
302    );
303    #[doc = "Get the `viewportOffsetY` field of this object."]
304    #[doc = ""]
305    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
306    #[wasm_bindgen(method, getter = "viewportOffsetY")]
307    pub fn get_viewport_offset_y(this: &MediaTrackConstraints) -> ::wasm_bindgen::JsValue;
308    #[doc = "Change the `viewportOffsetY` field of this object."]
309    #[doc = ""]
310    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
311    #[wasm_bindgen(method, setter = "viewportOffsetY")]
312    pub fn set_viewport_offset_y(this: &MediaTrackConstraints, val: &::wasm_bindgen::JsValue);
313    #[doc = "Change the `viewportOffsetY` field of this object."]
314    #[doc = ""]
315    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
316    #[wasm_bindgen(method, setter = "viewportOffsetY")]
317    pub fn set_viewport_offset_y_i32(this: &MediaTrackConstraints, val: i32);
318    #[cfg(feature = "ConstrainLongRange")]
319    #[doc = "Change the `viewportOffsetY` field of this object."]
320    #[doc = ""]
321    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
322    #[wasm_bindgen(method, setter = "viewportOffsetY")]
323    pub fn set_viewport_offset_y_constrain_long_range(
324        this: &MediaTrackConstraints,
325        val: &ConstrainLongRange,
326    );
327    #[doc = "Get the `viewportWidth` field of this object."]
328    #[doc = ""]
329    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
330    #[wasm_bindgen(method, getter = "viewportWidth")]
331    pub fn get_viewport_width(this: &MediaTrackConstraints) -> ::wasm_bindgen::JsValue;
332    #[doc = "Change the `viewportWidth` field of this object."]
333    #[doc = ""]
334    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
335    #[wasm_bindgen(method, setter = "viewportWidth")]
336    pub fn set_viewport_width(this: &MediaTrackConstraints, val: &::wasm_bindgen::JsValue);
337    #[doc = "Change the `viewportWidth` field of this object."]
338    #[doc = ""]
339    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
340    #[wasm_bindgen(method, setter = "viewportWidth")]
341    pub fn set_viewport_width_i32(this: &MediaTrackConstraints, val: i32);
342    #[cfg(feature = "ConstrainLongRange")]
343    #[doc = "Change the `viewportWidth` field of this object."]
344    #[doc = ""]
345    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
346    #[wasm_bindgen(method, setter = "viewportWidth")]
347    pub fn set_viewport_width_constrain_long_range(
348        this: &MediaTrackConstraints,
349        val: &ConstrainLongRange,
350    );
351    #[doc = "Get the `width` field of this object."]
352    #[doc = ""]
353    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
354    #[wasm_bindgen(method, getter = "width")]
355    pub fn get_width(this: &MediaTrackConstraints) -> ::wasm_bindgen::JsValue;
356    #[doc = "Change the `width` field of this object."]
357    #[doc = ""]
358    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
359    #[wasm_bindgen(method, setter = "width")]
360    pub fn set_width(this: &MediaTrackConstraints, val: &::wasm_bindgen::JsValue);
361    #[doc = "Change the `width` field of this object."]
362    #[doc = ""]
363    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
364    #[wasm_bindgen(method, setter = "width")]
365    pub fn set_width_i32(this: &MediaTrackConstraints, val: i32);
366    #[cfg(feature = "ConstrainLongRange")]
367    #[doc = "Change the `width` field of this object."]
368    #[doc = ""]
369    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
370    #[wasm_bindgen(method, setter = "width")]
371    pub fn set_width_constrain_long_range(this: &MediaTrackConstraints, val: &ConstrainLongRange);
372    #[doc = "Get the `advanced` field of this object."]
373    #[doc = ""]
374    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
375    #[wasm_bindgen(method, getter = "advanced")]
376    pub fn get_advanced(this: &MediaTrackConstraints) -> Option<::js_sys::Array>;
377    #[doc = "Change the `advanced` field of this object."]
378    #[doc = ""]
379    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
380    #[wasm_bindgen(method, setter = "advanced")]
381    pub fn set_advanced(this: &MediaTrackConstraints, val: &::wasm_bindgen::JsValue);
382}
383impl MediaTrackConstraints {
384    #[doc = "Construct a new `MediaTrackConstraints`."]
385    #[doc = ""]
386    #[doc = "*This API requires the following crate features to be activated: `MediaTrackConstraints`*"]
387    pub fn new() -> Self {
388        #[allow(unused_mut)]
389        let mut ret: Self = ::wasm_bindgen::JsCast::unchecked_into(::js_sys::Object::new());
390        ret
391    }
392    #[deprecated = "Use `set_auto_gain_control()` instead."]
393    pub fn auto_gain_control(&mut self, val: &::wasm_bindgen::JsValue) -> &mut Self {
394        self.set_auto_gain_control(val);
395        self
396    }
397    #[deprecated = "Use `set_browser_window()` instead."]
398    pub fn browser_window(&mut self, val: f64) -> &mut Self {
399        self.set_browser_window(val);
400        self
401    }
402    #[deprecated = "Use `set_channel_count()` instead."]
403    pub fn channel_count(&mut self, val: &::wasm_bindgen::JsValue) -> &mut Self {
404        self.set_channel_count(val);
405        self
406    }
407    #[deprecated = "Use `set_device_id()` instead."]
408    pub fn device_id(&mut self, val: &::wasm_bindgen::JsValue) -> &mut Self {
409        self.set_device_id(val);
410        self
411    }
412    #[deprecated = "Use `set_echo_cancellation()` instead."]
413    pub fn echo_cancellation(&mut self, val: &::wasm_bindgen::JsValue) -> &mut Self {
414        self.set_echo_cancellation(val);
415        self
416    }
417    #[deprecated = "Use `set_facing_mode()` instead."]
418    pub fn facing_mode(&mut self, val: &::wasm_bindgen::JsValue) -> &mut Self {
419        self.set_facing_mode(val);
420        self
421    }
422    #[deprecated = "Use `set_frame_rate()` instead."]
423    pub fn frame_rate(&mut self, val: &::wasm_bindgen::JsValue) -> &mut Self {
424        self.set_frame_rate(val);
425        self
426    }
427    #[deprecated = "Use `set_height()` instead."]
428    pub fn height(&mut self, val: &::wasm_bindgen::JsValue) -> &mut Self {
429        self.set_height(val);
430        self
431    }
432    #[deprecated = "Use `set_media_source()` instead."]
433    pub fn media_source(&mut self, val: &str) -> &mut Self {
434        self.set_media_source(val);
435        self
436    }
437    #[deprecated = "Use `set_noise_suppression()` instead."]
438    pub fn noise_suppression(&mut self, val: &::wasm_bindgen::JsValue) -> &mut Self {
439        self.set_noise_suppression(val);
440        self
441    }
442    #[deprecated = "Use `set_scroll_with_page()` instead."]
443    pub fn scroll_with_page(&mut self, val: bool) -> &mut Self {
444        self.set_scroll_with_page(val);
445        self
446    }
447    #[deprecated = "Use `set_viewport_height()` instead."]
448    pub fn viewport_height(&mut self, val: &::wasm_bindgen::JsValue) -> &mut Self {
449        self.set_viewport_height(val);
450        self
451    }
452    #[deprecated = "Use `set_viewport_offset_x()` instead."]
453    pub fn viewport_offset_x(&mut self, val: &::wasm_bindgen::JsValue) -> &mut Self {
454        self.set_viewport_offset_x(val);
455        self
456    }
457    #[deprecated = "Use `set_viewport_offset_y()` instead."]
458    pub fn viewport_offset_y(&mut self, val: &::wasm_bindgen::JsValue) -> &mut Self {
459        self.set_viewport_offset_y(val);
460        self
461    }
462    #[deprecated = "Use `set_viewport_width()` instead."]
463    pub fn viewport_width(&mut self, val: &::wasm_bindgen::JsValue) -> &mut Self {
464        self.set_viewport_width(val);
465        self
466    }
467    #[deprecated = "Use `set_width()` instead."]
468    pub fn width(&mut self, val: &::wasm_bindgen::JsValue) -> &mut Self {
469        self.set_width(val);
470        self
471    }
472    #[deprecated = "Use `set_advanced()` instead."]
473    pub fn advanced(&mut self, val: &::wasm_bindgen::JsValue) -> &mut Self {
474        self.set_advanced(val);
475        self
476    }
477}
478impl Default for MediaTrackConstraints {
479    fn default() -> Self {
480        Self::new()
481    }
482}