Skip to content

Filtering plugin/out of the box #8

@pehrlich

Description

@pehrlich

cc @nashira @paulmand3l

function LowPassFilter(cutoff) {
    var accumulator = 0;

    this.setCutoff = function (value) {
      cutoff = value;
    };

    this.sample = function(sample) {
      accumulator += (sample - accumulator) * cutoff;
      return accumulator;
    }
  }

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions