1 #![allow(unused_imports)] 2 use super::*; 3 use wasm_bindgen::prelude::*; 4 #[wasm_bindgen] 5 extern "C" { 6 # [wasm_bindgen (extends = AudioNode , extends = EventTarget , extends = :: js_sys :: Object , js_name = AnalyserNode , typescript_type = "AnalyserNode")] 7 #[derive(Debug, Clone, PartialEq, Eq)] 8 #[doc = "The `AnalyserNode` class."] 9 #[doc = ""] 10 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/AnalyserNode)"] 11 #[doc = ""] 12 #[doc = "*This API requires the following crate features to be activated: `AnalyserNode`*"] 13 pub type AnalyserNode; 14 # [wasm_bindgen (structural , method , getter , js_class = "AnalyserNode" , js_name = fftSize)] 15 #[doc = "Getter for the `fftSize` field of this object."] 16 #[doc = ""] 17 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/AnalyserNode/fftSize)"] 18 #[doc = ""] 19 #[doc = "*This API requires the following crate features to be activated: `AnalyserNode`*"] fft_size(this: &AnalyserNode) -> u3220 pub fn fft_size(this: &AnalyserNode) -> u32; 21 # [wasm_bindgen (structural , method , setter , js_class = "AnalyserNode" , js_name = fftSize)] 22 #[doc = "Setter for the `fftSize` field of this object."] 23 #[doc = ""] 24 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/AnalyserNode/fftSize)"] 25 #[doc = ""] 26 #[doc = "*This API requires the following crate features to be activated: `AnalyserNode`*"] set_fft_size(this: &AnalyserNode, value: u32)27 pub fn set_fft_size(this: &AnalyserNode, value: u32); 28 # [wasm_bindgen (structural , method , getter , js_class = "AnalyserNode" , js_name = frequencyBinCount)] 29 #[doc = "Getter for the `frequencyBinCount` field of this object."] 30 #[doc = ""] 31 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/AnalyserNode/frequencyBinCount)"] 32 #[doc = ""] 33 #[doc = "*This API requires the following crate features to be activated: `AnalyserNode`*"] frequency_bin_count(this: &AnalyserNode) -> u3234 pub fn frequency_bin_count(this: &AnalyserNode) -> u32; 35 # [wasm_bindgen (structural , method , getter , js_class = "AnalyserNode" , js_name = minDecibels)] 36 #[doc = "Getter for the `minDecibels` field of this object."] 37 #[doc = ""] 38 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/AnalyserNode/minDecibels)"] 39 #[doc = ""] 40 #[doc = "*This API requires the following crate features to be activated: `AnalyserNode`*"] min_decibels(this: &AnalyserNode) -> f6441 pub fn min_decibels(this: &AnalyserNode) -> f64; 42 # [wasm_bindgen (structural , method , setter , js_class = "AnalyserNode" , js_name = minDecibels)] 43 #[doc = "Setter for the `minDecibels` field of this object."] 44 #[doc = ""] 45 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/AnalyserNode/minDecibels)"] 46 #[doc = ""] 47 #[doc = "*This API requires the following crate features to be activated: `AnalyserNode`*"] set_min_decibels(this: &AnalyserNode, value: f64)48 pub fn set_min_decibels(this: &AnalyserNode, value: f64); 49 # [wasm_bindgen (structural , method , getter , js_class = "AnalyserNode" , js_name = maxDecibels)] 50 #[doc = "Getter for the `maxDecibels` field of this object."] 51 #[doc = ""] 52 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/AnalyserNode/maxDecibels)"] 53 #[doc = ""] 54 #[doc = "*This API requires the following crate features to be activated: `AnalyserNode`*"] max_decibels(this: &AnalyserNode) -> f6455 pub fn max_decibels(this: &AnalyserNode) -> f64; 56 # [wasm_bindgen (structural , method , setter , js_class = "AnalyserNode" , js_name = maxDecibels)] 57 #[doc = "Setter for the `maxDecibels` field of this object."] 58 #[doc = ""] 59 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/AnalyserNode/maxDecibels)"] 60 #[doc = ""] 61 #[doc = "*This API requires the following crate features to be activated: `AnalyserNode`*"] set_max_decibels(this: &AnalyserNode, value: f64)62 pub fn set_max_decibels(this: &AnalyserNode, value: f64); 63 # [wasm_bindgen (structural , method , getter , js_class = "AnalyserNode" , js_name = smoothingTimeConstant)] 64 #[doc = "Getter for the `smoothingTimeConstant` field of this object."] 65 #[doc = ""] 66 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/AnalyserNode/smoothingTimeConstant)"] 67 #[doc = ""] 68 #[doc = "*This API requires the following crate features to be activated: `AnalyserNode`*"] smoothing_time_constant(this: &AnalyserNode) -> f6469 pub fn smoothing_time_constant(this: &AnalyserNode) -> f64; 70 # [wasm_bindgen (structural , method , setter , js_class = "AnalyserNode" , js_name = smoothingTimeConstant)] 71 #[doc = "Setter for the `smoothingTimeConstant` field of this object."] 72 #[doc = ""] 73 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/AnalyserNode/smoothingTimeConstant)"] 74 #[doc = ""] 75 #[doc = "*This API requires the following crate features to be activated: `AnalyserNode`*"] set_smoothing_time_constant(this: &AnalyserNode, value: f64)76 pub fn set_smoothing_time_constant(this: &AnalyserNode, value: f64); 77 #[cfg(feature = "BaseAudioContext")] 78 #[wasm_bindgen(catch, constructor, js_class = "AnalyserNode")] 79 #[doc = "The `new AnalyserNode(..)` constructor, creating a new instance of `AnalyserNode`."] 80 #[doc = ""] 81 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/AnalyserNode/AnalyserNode)"] 82 #[doc = ""] 83 #[doc = "*This API requires the following crate features to be activated: `AnalyserNode`, `BaseAudioContext`*"] new(context: &BaseAudioContext) -> Result<AnalyserNode, JsValue>84 pub fn new(context: &BaseAudioContext) -> Result<AnalyserNode, JsValue>; 85 #[cfg(all(feature = "AnalyserOptions", feature = "BaseAudioContext",))] 86 #[wasm_bindgen(catch, constructor, js_class = "AnalyserNode")] 87 #[doc = "The `new AnalyserNode(..)` constructor, creating a new instance of `AnalyserNode`."] 88 #[doc = ""] 89 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/AnalyserNode/AnalyserNode)"] 90 #[doc = ""] 91 #[doc = "*This API requires the following crate features to be activated: `AnalyserNode`, `AnalyserOptions`, `BaseAudioContext`*"] new_with_options( context: &BaseAudioContext, options: &AnalyserOptions, ) -> Result<AnalyserNode, JsValue>92 pub fn new_with_options( 93 context: &BaseAudioContext, 94 options: &AnalyserOptions, 95 ) -> Result<AnalyserNode, JsValue>; 96 # [wasm_bindgen (method , structural , js_class = "AnalyserNode" , js_name = getByteFrequencyData)] 97 #[doc = "The `getByteFrequencyData()` method."] 98 #[doc = ""] 99 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/AnalyserNode/getByteFrequencyData)"] 100 #[doc = ""] 101 #[doc = "*This API requires the following crate features to be activated: `AnalyserNode`*"] get_byte_frequency_data(this: &AnalyserNode, array: &mut [u8])102 pub fn get_byte_frequency_data(this: &AnalyserNode, array: &mut [u8]); 103 # [wasm_bindgen (method , structural , js_class = "AnalyserNode" , js_name = getByteTimeDomainData)] 104 #[doc = "The `getByteTimeDomainData()` method."] 105 #[doc = ""] 106 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/AnalyserNode/getByteTimeDomainData)"] 107 #[doc = ""] 108 #[doc = "*This API requires the following crate features to be activated: `AnalyserNode`*"] get_byte_time_domain_data(this: &AnalyserNode, array: &mut [u8])109 pub fn get_byte_time_domain_data(this: &AnalyserNode, array: &mut [u8]); 110 # [wasm_bindgen (method , structural , js_class = "AnalyserNode" , js_name = getFloatFrequencyData)] 111 #[doc = "The `getFloatFrequencyData()` method."] 112 #[doc = ""] 113 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/AnalyserNode/getFloatFrequencyData)"] 114 #[doc = ""] 115 #[doc = "*This API requires the following crate features to be activated: `AnalyserNode`*"] get_float_frequency_data(this: &AnalyserNode, array: &mut [f32])116 pub fn get_float_frequency_data(this: &AnalyserNode, array: &mut [f32]); 117 # [wasm_bindgen (method , structural , js_class = "AnalyserNode" , js_name = getFloatTimeDomainData)] 118 #[doc = "The `getFloatTimeDomainData()` method."] 119 #[doc = ""] 120 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/AnalyserNode/getFloatTimeDomainData)"] 121 #[doc = ""] 122 #[doc = "*This API requires the following crate features to be activated: `AnalyserNode`*"] get_float_time_domain_data(this: &AnalyserNode, array: &mut [f32])123 pub fn get_float_time_domain_data(this: &AnalyserNode, array: &mut [f32]); 124 } 125