mirror of
https://github.com/livekit/livekit.git
synced 2026-10-15 15:30:14 +00:00
The key frame requester re-armed its timer on every loop, so every video down track woke up every 200 ms to 1 s for its whole life, even when the layer was locked and there was nothing to do. Re-arm the timer only while the requested layer is not locked, or while the lock can change without an event: an acquisition grace is armed, or layers are selected with the dependency descriptor, which can lose the lock on the packet path. Post the event on resync, mute, max published layer change and packet path layer switch, since those can change the lock without an allocation. Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>