Commit Graph

4 Commits

Author SHA1 Message Date
Raja Subramanian
85a23bfffc Cleaning up availableLayers and exemptedLayers (#1407)
* WIP commit

* Send stream state paused only when it is paused due to bandwidth limitation.

When stream is resumed after a stream is paused, an active update is
sent. Note that this means if there are intervening events like
mute/unmute between pause and resume, resume will be sent.

* WIP commit

* fix compile

* WIP commit

* fixing tests

* clean up exempted layers

* clean up unused stuff

* correct comment

* Don't need ops queue as order is not important now

* static check

* kick off allocation when callbacks are set up, calling from receiver means callbacks may not be set up
2023-02-17 13:53:11 +05:30
Raja Subramanian
cbc7d43ba4 Minor tweaks to frame based stream tracker. (#1281) 2023-01-03 18:16:55 +05:30
Raja Subramanian
a87574da31 FPS based stream tracker tweaks (#1275)
* FPS based stream tracker tweaks

- Cleaning up code
- Two tweaks
  o A layer is declared active on receiving first packet (when starting fresh).
    But, if there are no frames after that (no packets after girst packet or
    there is only one frame), layer would not have been declared stopped as
    the previous version waited for second frame. Now, if there are no more
    frames in eval interval, declare the layer stopped.
  o When frame rate goes to 0, reset FPS calculator. Otherwise, layer starting
    after a long time will have frames spaced apart too far which would result
    in very low frame rate. Reset the calculator and let it pick up after the
    the layer restarts
- Also changing from lowest FPS -> estimated FPS and update up slowly and down fast.
  There are cases where frames are to far apart result in really low FPS. Seems to
  happen with NLC kind of cases where bandwidth is changed rapidly and the estimator
  on browser probably gets a bit confused and starts/stops layers a bit erratically.
  So, update estimate periodically to ensure eval interval is tracking current rate.

* fix factor

* spelling fix
2022-12-30 19:49:16 +05:30
Raja Subramanian
2b031a5112 Introducing frame based stream tracker. (#1267)
* Split stream tracker impl from base

* slight re-arrangement of code

* fps based stream tracker

* MinFPS config

* switch back to packet based tracker

* use video config by default to handle sources without type
2022-12-28 13:00:21 +05:30