ipytone.Filter#

class ipytone.Filter(**kwargs: Any)#

Bases: AudioNode

Simple filter with rolloff (slope) parameter.

__init__(type='lowpass', frequency=350, q=1, detune=0, gain=0, rolloff=-12, **kwargs)#

Public constructor

Methods

chain(*nodes)

Connect the output of this audio node to the other audio nodes in series.

connect(destination[, output_number, ...])

Connect the output of this audio node to the input of another node.

disconnect(destination[, output_number, ...])

Disconnect the ouput of this audio node from a connected node.

dispose()

Dispose and disconnect this audio node (as well as its input/output).

fan(*destinations)

Connect the output of this audio node to the destinations audio nodes in parallel.

to_destination()

Convenience method to directly connect the output of this audio node to the main output (speakers) node.

Attributes

array

frequency response curve data (20hz-20kh)

array_length

Curve data resolution (array length)

channel_count

An int trait.

channel_count_mode

An enum whose value must be in a given sequence.

channel_interpretation

An enum whose value must be in a given sequence.

detune

Filter frequency detune.

disposed

Returns True if the node was disposed (i.e., disconnected and web audio node freed for garbage collection).

frequency

Filter frequency.

gain

Filter gain (value in decibels).

input

Returns the input node, or None if this node is a source.

log

A trait whose value must be an instance of a specified class.

name

A trait for unicode strings.

number_of_inputs

Returns the number of input slots for the input node (0 for source nodes).

number_of_outputs

Returns the number of output slots for the output node (0 for sink nodes).

output

Returns the output node, or None if this node is a sink.

q

Filter Q factor.

rolloff

filter rolloff (slope)

sync_array

If True, synchronize curve data

type

filter type

array#

frequency response curve data (20hz-20kh)

array_length#

Curve data resolution (array length)

chain(*nodes)#

Connect the output of this audio node to the other audio nodes in series.

connect(destination, output_number=0, input_number=0)#

Connect the output of this audio node to the input of another node.

Parameters:
  • destination (AudioNode or NativeAudioNode or Param or NativeAudioParam) – The destination node.

  • output_number (int) – The channel number of the output of this node (default: 0).

  • input_number (int) – The channel number of the input of the destination node (default: 0).

property detune: Signal#

Filter frequency detune.

disconnect(destination, output_number=0, input_number=0)#

Disconnect the ouput of this audio node from a connected node.

Parameters:
  • destination (AudioNode or NativeAudioNode or Param or NativeAudioParam) – The connected destination node.

  • output_number (int) – The channel number of the output of this node (default: 0).

  • input_number (int) – The channel number of the input of the destination node (default: 0).

dispose()#

Dispose and disconnect this audio node (as well as its input/output).

property disposed#

Returns True if the node was disposed (i.e., disconnected and web audio node freed for garbage collection).

fan(*destinations)#

Connect the output of this audio node to the destinations audio nodes in parallel.

property frequency: Signal#

Filter frequency.

property gain: Signal#

Filter gain (value in decibels).

Only used for lowshelf, highshelf, and peaking filters.

property input#

Returns the input node, or None if this node is a source.

property number_of_inputs#

Returns the number of input slots for the input node (0 for source nodes).

property number_of_outputs#

Returns the number of output slots for the output node (0 for sink nodes).

property output#

Returns the output node, or None if this node is a sink.

property q: Signal#

Filter Q factor.

rolloff#

filter rolloff (slope)

sync_array#

If True, synchronize curve data

to_destination()#

Convenience method to directly connect the output of this audio node to the main output (speakers) node.

type#

filter type