Skip to content

Module pippi.filter

None

None

View Source
from pippi import dsp

class Filter:

    def process(self):

        out = dsp.buffer(length=self.snd.dur, channels=self.snd.channels, samplerate=self.snd.samplerate)

        filter_params = {}

        for i, callback, params in enumerate(self.filters):

            filter_params[i] = params

        for i in range(len(out)):

            for c in range(out.channels):

                out[i, c] = self._process(out[i, c], self.params)

        return out

Classes

Filter

class Filter(
    /,
    *args,
    **kwargs
)
View Source
class Filter:

    def process(self):

        out = dsp.buffer(length=self.snd.dur, channels=self.snd.channels, samplerate=self.snd.samplerate)

        filter_params = {}

        for i, callback, params in enumerate(self.filters):

            filter_params[i] = params

        for i in range(len(out)):

            for c in range(out.channels):

                out[i, c] = self._process(out[i, c], self.params)

        return out

Methods

process

def process(
    self
)
View Source
    def process(self):

        out = dsp.buffer(length=self.snd.dur, channels=self.snd.channels, samplerate=self.snd.samplerate)

        filter_params = {}

        for i, callback, params in enumerate(self.filters):

            filter_params[i] = params

        for i in range(len(out)):

            for c in range(out.channels):

                out[i, c] = self._process(out[i, c], self.params)

        return out