filter

package
v1.8.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 16, 2023 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	CHANNEL_COUNT = 1
)

* Global constants.

Variables

This section is empty.

Functions

func SampleRates

func SampleRates() []uint32

* Returns the supported sample rates.

Types

type Filter

type Filter interface {
	Add(other Filter) (Filter, error)
	Coefficients() []float64
	Multiply(scalar float64) Filter
	Normalize() Filter
	Process(inputBuffer []float64, outputBuffer []float64) error
	Reduce(order uint32) Filter
	SampleRate() uint32
}

* Interface type representing an FIR filter.

func Empty

func Empty(sampleRate uint32) Filter

* Create an empty filter, which does not pass any signal.

func FromCoefficients added in v1.5.0

func FromCoefficients(coeffs []float64, sampleRate uint32, name string) Filter

* Creates a filter from a list of coefficients.

type ImpulseResponses

type ImpulseResponses interface {
	CreateFilter(name string, sampleRate uint32) Filter
	Names() []string
}

* Interface type representing a collection of impulse responses.

func Import

func Import(descriptorFilePath string) (ImpulseResponses, error)

* Imports a set of impulse responses using a descriptor file.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL