audio

package
v1.4.3-dev5 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ConvertAudioLevel

func ConvertAudioLevel(level float64) float64

convert decibel back to linear

Types

type AudioLevel

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

keeps track of audio level for a participant

func NewAudioLevel

func NewAudioLevel(params AudioLevelParams) *AudioLevel

func (*AudioLevel) GetLevel

func (l *AudioLevel) GetLevel() (float64, bool)

returns current soothed audio level

func (*AudioLevel) Observe

func (l *AudioLevel) Observe(level uint8, durationMs uint32)

Observes a new frame, must be called from the same thread

type AudioLevelParams

type AudioLevelParams struct {
	ActiveLevel     uint8
	MinPercentile   uint8
	ObserveDuration uint32
	SmoothIntervals uint32
}

Jump to

Keyboard shortcuts

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