module

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Oct 4, 2025 License: Unlicense Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Envelope

type Envelope struct {
	Module
	Attack  float64 `yaml:"attack"`
	Decay   float64 `yaml:"decay"`
	Release float64 `yaml:"release"`
	Peak    float64 `yaml:"peak"`
	Level   float64 `yaml:"level"`
	Gate    string  `yaml:"gate"`
	// contains filtered or unexported fields
}

func (*Envelope) Step

func (e *Envelope) Step(t float64, modules ModuleMap)

type EnvelopeMap

type EnvelopeMap map[string]*Envelope

func (EnvelopeMap) Initialize

func (m EnvelopeMap) Initialize()

type Filter

type Filter struct {
	Module
	Type  filterType `yaml:"type"`
	Freq  float64    `yaml:"freq"`
	Width float64    `yaml:"width"`
	CV    string     `yaml:"cv"`
	Mod   string     `yaml:"mod"`
	In    string     `yaml:"in"`
	// contains filtered or unexported fields
}

func (*Filter) Step

func (f *Filter) Step(modules ModuleMap)

type FilterMap

type FilterMap map[string]*Filter

func (FilterMap) Initialize

func (m FilterMap) Initialize(sampleRate float64) error

type Gate

type Gate struct {
	Module
	BPM    float64   `yaml:"bpm"`
	CV     string    `yaml:"cv"`
	Mod    string    `yaml:"mod"`
	Signal []float64 `yaml:"signal"`
	// contains filtered or unexported fields
}

func (*Gate) Step

func (g *Gate) Step(modules ModuleMap)

type GateMap

type GateMap map[string]*Gate

func (GateMap) Initialze

func (m GateMap) Initialze(sampleRate float64)

type IModule

type IModule interface {
	Current() Output
}

type Mixer

type Mixer struct {
	Module
	Gain float64            `yaml:"gain"`
	CV   string             `yaml:"cv"`
	Mod  string             `yaml:"mod"`
	In   map[string]float64 `yaml:"in"`
	// contains filtered or unexported fields
}

func (*Mixer) Step

func (m *Mixer) Step(modules ModuleMap)

type MixerMap

type MixerMap map[string]*Mixer

func (MixerMap) Initialize

func (m MixerMap) Initialize(sampleRate float64) error

type Module

type Module struct {
	// contains filtered or unexported fields
}

func (*Module) Current

func (m *Module) Current() Output

type ModuleMap

type ModuleMap map[string]IModule

type Noise

type Noise struct {
	Module
}

func (*Noise) Step

func (n *Noise) Step()

type NoiseMap

type NoiseMap map[string]*Noise

type Oscillator

type Oscillator struct {
	Module
	Type  oscillatorType `yaml:"type"`
	Freq  float64        `yaml:"freq"`
	CV    string         `yaml:"cv"`
	Mod   string         `yaml:"mod"`
	Phase float64        `yaml:"phase"`
	// contains filtered or unexported fields
}

func (*Oscillator) Step

func (o *Oscillator) Step(modules ModuleMap)

type OscillatorMap

type OscillatorMap map[string]*Oscillator

func (OscillatorMap) Initialize

func (m OscillatorMap) Initialize(sampleRate float64) error

type Output

type Output struct {
	Mono, Left, Right float64
}

type Pan

type Pan struct {
	Module
	Pan float64 `yaml:"pan"`
	Mod string  `yaml:"mod"`
	In  string  `yaml:"in"`
}

func (*Pan) Step

func (p *Pan) Step(modules ModuleMap)

type PanMap

type PanMap map[string]*Pan

func (PanMap) Initialize

func (m PanMap) Initialize()

type Sampler

type Sampler struct {
	Module
	In      string `yaml:"in"`
	Trigger string `yaml:"trigger"`
	// contains filtered or unexported fields
}

func (*Sampler) Step

func (s *Sampler) Step(modules ModuleMap)

type SamplerMap

type SamplerMap map[string]*Sampler

type Sequencer

type Sequencer struct {
	Module
	Sequence  []string `yaml:"sequence"`
	Trigger   string   `yaml:"trigger"`
	Pitch     float64  `yaml:"pitch"`
	Transpose float64  `yaml:"transpose"`
	Randomize bool     `yaml:"randomize"`
	// contains filtered or unexported fields
}

func (*Sequencer) Step

func (s *Sequencer) Step(modules ModuleMap)

type SequencerMap

type SequencerMap map[string]*Sequencer

func (SequencerMap) Initialize

func (m SequencerMap) Initialize() error

type SignalFunc

type SignalFunc func(x float64) float64

func NoSignalFunc

func NoSignalFunc() SignalFunc

func ReverseSawtoothSignalFunc

func ReverseSawtoothSignalFunc() SignalFunc

func SawtoothSignalFunc

func SawtoothSignalFunc() SignalFunc

func SineSignalFunc

func SineSignalFunc() SignalFunc

func SquareSignalFunc

func SquareSignalFunc() SignalFunc

func TriangleSignalFunc

func TriangleSignalFunc() SignalFunc

type Wavetable

type Wavetable struct {
	Module
	Freq   float64   `yaml:"freq"`
	CV     string    `yaml:"cv"`
	Mod    string    `yaml:"mod"`
	Signal []float64 `yaml:"signal"`
	// contains filtered or unexported fields
}

func (*Wavetable) Step

func (w *Wavetable) Step(modules ModuleMap)

type WavetableMap

type WavetableMap map[string]*Wavetable

func (WavetableMap) Initialize

func (m WavetableMap) Initialize(sampleRate float64)

Jump to

Keyboard shortcuts

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