Propagate spreader threshold to RED receivers. (#4683)

Following up on this PR (https://github.com/livekit/livekit/pull/4678 -
great catch btw, thank you), propagating the spreader threshold to RED
receivers also.

Removing the test as it was a simple case and that would not have caught
the original issue.
This commit is contained in:
Raja Subramanian
2026-07-17 02:25:10 +05:30
committed by GitHub
parent 15a9542c99
commit 2c91395055
4 changed files with 12 additions and 42 deletions
+4
View File
@@ -61,6 +61,10 @@ func NewRedPrimaryReceiver(receiver TrackReceiver, dsp utils.DownTrackSpreaderPa
}
}
func (r *RedPrimaryReceiver) SetLBThreshold(lbThreshold int) {
r.downTrackSpreader.SetThreshold(lbThreshold)
}
func (r *RedPrimaryReceiver) ForwardRTP(pkt *buffer.ExtPacket, spatialLayer int32) int32 {
// extract primary payload from RED and forward to downtracks
if r.downTrackSpreader.DownTrackCount() == 0 {