BaseAudioContext.createIIRFilter() - Web APIs 编辑
The createIIRFilter()
method of the BaseAudioContext
interface creates an IIRFilterNode
, which represents a general infinite impulse response (IIR) filter which can be configured to serve as various types of filter.
Syntax
var iirFilter = AudioContext.createIIRFilter(feedforward, feedback);
Parameters
feedforward
- An array of floating-point values specifying the feedforward (numerator) coefficients for the transfer function of the IIR filter. The maximum length of this array is 20, and at least one value must be nonzero.
feedback
- An array of floating-point values specifying the feedback (denominator) coefficients for the transfer function of the IIR filter. This array may have up to 20 members, the first of which must not be zero.
Return value
An IIRFilterNode
implementing the filter with the specified feedback and feedforward coefficient arrays.
Exceptions
InvalidStateError
- All of the
feedforward
coefficients are 0, and/or the firstfeedback
coefficient is 0. NotSupportedError
- One or both of the input arrays exceeds 20 members.
Specifications
Specification | Status | Comment |
---|---|---|
Web Audio API The definition of 'createIIRFilter()' in that specification. | Working Draft |
Browser compatibility
BCD tables only load in the browser
See also
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论