portaudio

package
v1.2.0 Latest Latest
Warning

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

Go to latest
Published: Jan 7, 2020 License: MIT Imports: 3 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type PortAudio

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

func New

func New(l astikit.StdLogger) *PortAudio

func (*PortAudio) Close

func (p *PortAudio) Close() (err error)

func (*PortAudio) Info

func (p *PortAudio) Info() (s string)

func (*PortAudio) Initialize

func (p *PortAudio) Initialize() (err error)

func (*PortAudio) NewDefaultStream

func (p *PortAudio) NewDefaultStream(o StreamOptions) (s *Stream, err error)

type Stream

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

func (*Stream) BitDepth

func (s *Stream) BitDepth() int

func (*Stream) Close

func (s *Stream) Close() (err error)

func (*Stream) MaxSilenceLevel added in v1.1.0

func (s *Stream) MaxSilenceLevel() float64

func (*Stream) NumChannels

func (s *Stream) NumChannels() int

func (*Stream) Read

func (s *Stream) Read() (rs []int, err error)

func (*Stream) SampleRate

func (s *Stream) SampleRate() int

func (*Stream) Start

func (s *Stream) Start() (err error)

func (*Stream) Stop

func (s *Stream) Stop() (err error)

type StreamOptions

type StreamOptions struct {
	BitDepth          int     `toml:"bit_depth"`
	BufferLength      int     `toml:"buffer_length"`
	MaxSilenceLevel   float64 `toml:"max_silence_level"`
	NumInputChannels  int     `toml:"num_input_channels"`
	NumOutputChannels int     `toml:"num_output_channels"`
	SampleRate        int     `toml:"sample_rate"`
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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