We are using a WebRTC implementation (built from AOSP) to stream the UI of a virtualized Android Cuttlefish device to a remote client. This setup is characterized by variable frame rate: During inactivity (static screen/home screen) the encoder receives frames only when the screen updates (e.g., once every 60 seconds for a clock tick). During activity (animation/input) the encoder outputs bursts of complex frames at 30-60 FPS.
Immediately following a long period of inactivity (idle screen), the system seems to fail to transition correctly to the active state, leading to a bitrate collapse:
1. The check_encoder_activity_task_ runs during silence and finds no activity.
2. It triggers SignalEncoderTimedOut() because the time since the last frame production is greater than kEncoderTimeOut.
3. total_requested_max_bitrate seem to be reset to very low value like 54kbps
4. This causes severe lag and high packet retransmission rates when the animation burst finally begins.
I think the timeout is a false positive because the encoder is not hung; it is correctly idle and waiting for the next frame. The timeout logic seems inappropriate for variable frame rate sources where silence is expected.
Should the encoder activity check be disabled when the stream is known to be a screen-share?
Best Regards,
Mikko Koivisto
--
This list falls under the WebRTC Code of Conduct - https://webrtc.org/support/code-of-conduct.
---
You received this message because you are subscribed to the Google Groups "discuss-webrtc" group.
To unsubscribe from this group and stop receiving emails from it, send an email to discuss-webrt...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/discuss-webrtc/37a3f864-be25-45a1-b98f-2d6253228e46n%40googlegroups.com.
--
Thanks for the tips,
I'll try feeding 1fps constant frame stream to encoder on idle. I have already tested
WebRTC-Pacer-PadInSilence/Enabled/
...which I think is somewhat similar to periodic_alr_bandwidth_probing and tries to prevent the bwe from decaying during media silence.