connectionquality

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Jun 22, 2022 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (
	UpdateInterval = 2 * time.Second
)

Variables

This section is empty.

Functions

func AudioTrackScore added in v1.1.0

func AudioTrackScore(params TrackScoreParams) float32

func Score2Rating

func Score2Rating(score float32) livekit.ConnectionQuality

func ScreenshareTrackScore added in v1.1.0

func ScreenshareTrackScore(params TrackScoreParams) float32

rtcmos gives lower score when screen share content is static. Even though the frame rate is low, the bit rate is also low and the resolution is high. Till rtcmos model can be adapted to that scenario, use loss based scoring.

func ToAnalyticsStream added in v0.15.4

func ToAnalyticsStream(ssrc uint32, deltaStats *buffer.RTPDeltaInfo) *livekit.AnalyticsStream

func ToAnalyticsVideoLayer added in v0.15.4

func ToAnalyticsVideoLayer(layer int32, layerStats *buffer.RTPDeltaInfo) *livekit.AnalyticsVideoLayer

func VideoTrackScore added in v1.1.0

func VideoTrackScore(params TrackScoreParams) float32

Types

type ConnectionStats

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

func NewConnectionStats

func NewConnectionStats(params ConnectionStatsParams) *ConnectionStats

func (*ConnectionStats) Close added in v0.15.3

func (cs *ConnectionStats) Close()

func (*ConnectionStats) GetScore added in v0.15.3

func (cs *ConnectionStats) GetScore() float32

func (*ConnectionStats) OnStatsUpdate added in v0.15.3

func (cs *ConnectionStats) OnStatsUpdate(fn func(cs *ConnectionStats, stat *livekit.AnalyticsStat))

func (*ConnectionStats) SetTrackSource added in v1.1.0

func (cs *ConnectionStats) SetTrackSource(trackSource livekit.TrackSource)

func (*ConnectionStats) Start added in v0.15.3

func (cs *ConnectionStats) Start()

type ConnectionStatsParams added in v0.15.3

type ConnectionStatsParams struct {
	UpdateInterval         time.Duration
	CodecType              webrtc.RTPCodecType
	CodecName              string
	MimeType               string
	GetDeltaStats          func() map[uint32]*buffer.StreamStatsWithLayers
	IsDtxDisabled          func() bool
	GetLayerDimension      func(int32) (uint32, uint32)
	GetMaxExpectedLayer    func() (int32, uint32, uint32)
	GetCurrentLayerSpatial func() int32
	GetIsReducedQuality    func() bool
	Logger                 logger.Logger
}

type TrackScoreParams added in v1.1.0

type TrackScoreParams struct {
	Duration         time.Duration
	Codec            string
	PacketsExpected  uint32
	PacketsLost      uint32
	Bytes            uint64
	Frames           uint32
	Jitter           float64
	Rtt              uint32
	DtxDisabled      bool
	ActualWidth      uint32
	ActualHeight     uint32
	ExpectedWidth    uint32
	ExpectedHeight   uint32
	IsReducedQuality bool
}

Jump to

Keyboard shortcuts

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