Skip to main content

web_sys/features/
gen_AudioParam.rs

1#![allow(unused_imports)]
2#![allow(clippy::all)]
3use super::*;
4use wasm_bindgen::prelude::*;
5#[wasm_bindgen]
6extern "C" {
7    #[wasm_bindgen(
8        extends = "::js_sys::Object",
9        js_name = "AudioParam",
10        typescript_type = "AudioParam"
11    )]
12    #[derive(Debug, Clone, PartialEq, Eq)]
13    #[doc = "The `AudioParam` class."]
14    #[doc = ""]
15    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/AudioParam)"]
16    #[doc = ""]
17    #[doc = "*This API requires the following crate features to be activated: `AudioParam`*"]
18    pub type AudioParam;
19    #[wasm_bindgen(method, getter, js_class = "AudioParam", js_name = "value")]
20    #[doc = "Getter for the `value` field of this object."]
21    #[doc = ""]
22    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/AudioParam/value)"]
23    #[doc = ""]
24    #[doc = "*This API requires the following crate features to be activated: `AudioParam`*"]
25    pub fn value(this: &AudioParam) -> f32;
26    #[wasm_bindgen(method, setter, js_class = "AudioParam", js_name = "value")]
27    #[doc = "Setter for the `value` field of this object."]
28    #[doc = ""]
29    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/AudioParam/value)"]
30    #[doc = ""]
31    #[doc = "*This API requires the following crate features to be activated: `AudioParam`*"]
32    pub fn set_value(this: &AudioParam, value: f32);
33    #[wasm_bindgen(method, getter, js_class = "AudioParam", js_name = "defaultValue")]
34    #[doc = "Getter for the `defaultValue` field of this object."]
35    #[doc = ""]
36    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/AudioParam/defaultValue)"]
37    #[doc = ""]
38    #[doc = "*This API requires the following crate features to be activated: `AudioParam`*"]
39    pub fn default_value(this: &AudioParam) -> f32;
40    #[wasm_bindgen(method, getter, js_class = "AudioParam", js_name = "minValue")]
41    #[doc = "Getter for the `minValue` field of this object."]
42    #[doc = ""]
43    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/AudioParam/minValue)"]
44    #[doc = ""]
45    #[doc = "*This API requires the following crate features to be activated: `AudioParam`*"]
46    pub fn min_value(this: &AudioParam) -> f32;
47    #[wasm_bindgen(method, getter, js_class = "AudioParam", js_name = "maxValue")]
48    #[doc = "Getter for the `maxValue` field of this object."]
49    #[doc = ""]
50    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/AudioParam/maxValue)"]
51    #[doc = ""]
52    #[doc = "*This API requires the following crate features to be activated: `AudioParam`*"]
53    pub fn max_value(this: &AudioParam) -> f32;
54    #[wasm_bindgen(
55        catch,
56        method,
57        js_class = "AudioParam",
58        js_name = "cancelScheduledValues"
59    )]
60    #[doc = "The `cancelScheduledValues()` method."]
61    #[doc = ""]
62    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/AudioParam/cancelScheduledValues)"]
63    #[doc = ""]
64    #[doc = "*This API requires the following crate features to be activated: `AudioParam`*"]
65    pub fn cancel_scheduled_values(
66        this: &AudioParam,
67        start_time: f64,
68    ) -> Result<AudioParam, JsValue>;
69    #[wasm_bindgen(
70        catch,
71        method,
72        js_class = "AudioParam",
73        js_name = "exponentialRampToValueAtTime"
74    )]
75    #[doc = "The `exponentialRampToValueAtTime()` method."]
76    #[doc = ""]
77    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/AudioParam/exponentialRampToValueAtTime)"]
78    #[doc = ""]
79    #[doc = "*This API requires the following crate features to be activated: `AudioParam`*"]
80    pub fn exponential_ramp_to_value_at_time(
81        this: &AudioParam,
82        value: f32,
83        end_time: f64,
84    ) -> Result<AudioParam, JsValue>;
85    #[wasm_bindgen(
86        catch,
87        method,
88        js_class = "AudioParam",
89        js_name = "linearRampToValueAtTime"
90    )]
91    #[doc = "The `linearRampToValueAtTime()` method."]
92    #[doc = ""]
93    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/AudioParam/linearRampToValueAtTime)"]
94    #[doc = ""]
95    #[doc = "*This API requires the following crate features to be activated: `AudioParam`*"]
96    pub fn linear_ramp_to_value_at_time(
97        this: &AudioParam,
98        value: f32,
99        end_time: f64,
100    ) -> Result<AudioParam, JsValue>;
101    #[wasm_bindgen(catch, method, js_class = "AudioParam", js_name = "setTargetAtTime")]
102    #[doc = "The `setTargetAtTime()` method."]
103    #[doc = ""]
104    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/AudioParam/setTargetAtTime)"]
105    #[doc = ""]
106    #[doc = "*This API requires the following crate features to be activated: `AudioParam`*"]
107    pub fn set_target_at_time(
108        this: &AudioParam,
109        target: f32,
110        start_time: f64,
111        time_constant: f64,
112    ) -> Result<AudioParam, JsValue>;
113    #[wasm_bindgen(catch, method, js_class = "AudioParam", js_name = "setValueAtTime")]
114    #[doc = "The `setValueAtTime()` method."]
115    #[doc = ""]
116    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/AudioParam/setValueAtTime)"]
117    #[doc = ""]
118    #[doc = "*This API requires the following crate features to be activated: `AudioParam`*"]
119    pub fn set_value_at_time(
120        this: &AudioParam,
121        value: f32,
122        start_time: f64,
123    ) -> Result<AudioParam, JsValue>;
124    #[wasm_bindgen(
125        catch,
126        method,
127        js_class = "AudioParam",
128        js_name = "setValueCurveAtTime"
129    )]
130    #[doc = "The `setValueCurveAtTime()` method."]
131    #[doc = ""]
132    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/AudioParam/setValueCurveAtTime)"]
133    #[doc = ""]
134    #[doc = "*This API requires the following crate features to be activated: `AudioParam`*"]
135    pub fn set_value_curve_at_time(
136        this: &AudioParam,
137        values: &mut [f32],
138        start_time: f64,
139        duration: f64,
140    ) -> Result<AudioParam, JsValue>;
141    #[wasm_bindgen(
142        catch,
143        method,
144        js_class = "AudioParam",
145        js_name = "setValueCurveAtTime"
146    )]
147    #[doc = "The `setValueCurveAtTime()` method."]
148    #[doc = ""]
149    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/AudioParam/setValueCurveAtTime)"]
150    #[doc = ""]
151    #[doc = "*This API requires the following crate features to be activated: `AudioParam`*"]
152    pub fn set_value_curve_at_time_with_f32_array(
153        this: &AudioParam,
154        values: &::js_sys::Float32Array,
155        start_time: f64,
156        duration: f64,
157    ) -> Result<AudioParam, JsValue>;
158}