Documentation ¶
Index ¶
- Variables
- type Int24
- type Matrix
- func (m *Matrix) Accumulate(in Matrix)
- func (m Matrix) Apply(vol Volume) Matrix
- func (m Matrix) ApplyToMatrix(mtx Matrix) Matrix
- func (m Matrix) AsMono() Matrix
- func (m Matrix) AsQuad() Matrix
- func (m Matrix) AsStereo() Matrix
- func (m *Matrix) Assign(channels int, data []Volume)
- func (m Matrix) Get(ch int) Volume
- func (m Matrix) Lerp(other Matrix, t float32) Matrix
- func (m *Matrix) Set(ch int, vol Volume)
- func (m Matrix) Sum() Volume
- func (m Matrix) ToChannels(channels int) Matrix
- type StaticMatrix
- type Volume
- func (v Volume) ApplyMultiple(samp []Volume) []Volume
- func (v Volume) ApplySingle(samp Volume) Volume
- func (v Volume) String() string
- func (v Volume) ToIntSample(bitsPerSample int) int32
- func (v Volume) ToSample(bitsPerSample int) interface{}
- func (v Volume) ToUintSample(bitsPerSample int) uint32
- func (v Volume) WithOverflowProtection() float64
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // VolumeUseInstVol tells the system to use the volume stored on the instrument // This is useful for trackers and other musical applications VolumeUseInstVol = Volume(math.Inf(-1)) )
Functions ¶
This section is empty.
Types ¶
type Matrix ¶
type Matrix struct { StaticMatrix Channels int }
Matrix is an array of Volumes
func (*Matrix) Accumulate ¶ added in v1.1.0
func (Matrix) ApplyToMatrix ¶ added in v1.1.0
Apply takes a volume matrix and multiplies it by incoming volumes
func (Matrix) ToChannels ¶ added in v1.1.0
type Volume ¶
type Volume float32
Volume is a mixable volume
func (Volume) ApplyMultiple ¶ added in v1.1.0
Apply multiplies the volume to 1 sample, then returns the results
func (Volume) ApplySingle ¶ added in v1.1.0
Apply multiplies the volume to 1 sample, then returns the results
func (Volume) ToIntSample ¶
ToIntSample returns a volume as an int32 value ranged to the bits per sample provided
func (Volume) ToSample ¶
ToSample returns a volume as a typed value supporting the bits per sample provided
func (Volume) ToUintSample ¶ added in v1.2.0
ToUintSample returns a volume as a uint32 value ranged to the bits per sample provided
func (Volume) WithOverflowProtection ¶ added in v1.2.0
Click to show internal directories.
Click to hide internal directories.