Support simulating subscriber bandwidth. (#1609)
* Support simualting subscriber bandwidth. When non-zero, a full allocation is triggered. Also, probes are stopped. When set to zero, normal probing mechanism should catch up. Adding `allowPause` override which can be a connection option. * fix log * allowPause in participant params
This commit is contained in:
@@ -88,6 +88,7 @@ type ParticipantParams struct {
|
||||
VersionGenerator utils.TimedVersionGenerator
|
||||
TrackResolver types.MediaTrackResolver
|
||||
DisableDynacast bool
|
||||
SubscriberAllowPause bool
|
||||
}
|
||||
|
||||
type ParticipantImpl struct {
|
||||
@@ -1035,6 +1036,8 @@ func (p *ParticipantImpl) setupTransportManager() error {
|
||||
tm.OnAnyTransportNegotiationFailed(p.onAnyTransportNegotiationFailed)
|
||||
|
||||
tm.OnDataMessage(p.onDataMessage)
|
||||
|
||||
tm.SetSubscriberAllowPause(p.params.SubscriberAllowPause)
|
||||
p.TransportManager = tm
|
||||
return nil
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user