Frame rate controller per spatial layer.

This allows VP9 encoder wrapper to control frame rate of each spatial
layer. The wrapper configures encoder to skip encoding spatial layer
when actual frame rate exceeds the target frame rate of that layer.
Target frame rate of high spatial layer is expected to be equal or
higher then that of low spatial layer. For now frame rate controller
is only enabled in screen sharing mode.

Added unit test which configures encoder to produce 3 spatial layers
with frame rates 10, 20 and 30fps and verifies that absolute delta of
final and target rate doesn't exceed 10%.

Bug: webrtc:9682
Change-Id: I7a7833f63927dd475e7b42d43e4d29061613e64e
Reviewed-on: https://webrtc-review.googlesource.com/96640
Commit-Queue: Sergey Silkin <ssilkin@webrtc.org>
Reviewed-by: Erik Språng <sprang@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24593}
This commit is contained in:
Sergey Silkin
2018-09-05 21:07:17 +02:00
committed by Commit Bot
parent afa12d0cee
commit ae9e188e67
3 changed files with 137 additions and 21 deletions

View File

@ -117,8 +117,7 @@ class VP9EncoderImpl : public VP9Encoder {
bool is_svc_;
InterLayerPredMode inter_layer_pred_;
// Framerate controller.
FramerateController framerate_controller_;
std::vector<FramerateController> framerate_controller_;
// Used for flexible mode.
bool is_flexible_mode_;