fix(video): determine svc/simulcast from SDP for advanced codecs (#3549)

* fix(video): determine svc/simulcast from SDP for advanced codecs

* fix(explicit-svc): cleanup

* fix(explicit-svc): remove from list on close/remove

* fix(explicit-svc): reorder VLS selection, cleanup

* fix(explicit-svc): todo comments for temporal layer selector

* fix(explicit-svc): remove from simulcastTrackIds even if client does not support unpublish
This commit is contained in:
Anunay Maheshwari
2025-03-26 16:22:32 +05:30
committed by GitHub
parent 2b6a46f402
commit 15f565510c
14 changed files with 168 additions and 216 deletions
+6 -4
View File
@@ -498,9 +498,11 @@ func (t *MediaTrackReceiver) SetSimulcast(simulcast bool) {
t.lock.Lock()
defer t.lock.Unlock()
trackInfo := t.TrackInfoClone()
trackInfo.Simulcast = simulcast
t.trackInfo.Store(trackInfo)
if t.IsSimulcast() != simulcast {
trackInfo := t.TrackInfoClone()
trackInfo.Simulcast = simulcast
t.trackInfo.Store(trackInfo)
}
}
func (t *MediaTrackReceiver) Name() string {
@@ -593,7 +595,7 @@ func (t *MediaTrackReceiver) AddSubscriber(sub types.LocalParticipant) (types.Su
Logger: tLogger,
DisableRed: t.TrackInfo().GetDisableRed() || !t.params.AudioConfig.ActiveREDEncoding,
})
subTrack, err := t.MediaTrackSubscriptions.AddSubscriber(sub, wr)
subTrack, err := t.MediaTrackSubscriptions.AddSubscriber(sub, wr, t.IsSimulcast())
// media track could have been closed while adding subscription
remove := false