From b39fce858f0dc76c6dce13aeee1b7b738d06053a Mon Sep 17 00:00:00 2001 From: Evan Shrubsole Date: Fri, 21 Jan 2022 14:51:18 +0100 Subject: [PATCH] [frame-buffer3] Enable WebRTC-LegacyFrameIdJumpBehavior by default When disabled, the test ResolutionAdaptsToAvailableBandwidth fails when using frame buffer3. It is not clear if that is a problem with the test or if that behaviour is required, and thus it is safer to have this enabled by default and experiment with turning it off in the future. Change-Id: I7a6ae14c37a0cdc3e203f39f6cc0c3ad87038a60 Bug: webrtc:13343 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/247700 Reviewed-by: Philip Eliasson Commit-Queue: Evan Shrubsole Cr-Commit-Position: refs/heads/main@{#35764} --- modules/video_coding/frame_buffer3.cc | 2 +- modules/video_coding/frame_buffer3_unittest.cc | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/modules/video_coding/frame_buffer3.cc b/modules/video_coding/frame_buffer3.cc index 32de3683c7..56eac0e6a1 100644 --- a/modules/video_coding/frame_buffer3.cc +++ b/modules/video_coding/frame_buffer3.cc @@ -65,7 +65,7 @@ bool IsLastFrameInTemporalUnit(const FrameIteratorT& it) { FrameBuffer::FrameBuffer(int max_size, int max_decode_history) : legacy_frame_id_jump_behavior_( - field_trial::IsEnabled("WebRTC-LegacyFrameIdJumpBehavior")), + !field_trial::IsDisabled("WebRTC-LegacyFrameIdJumpBehavior")), max_size_(max_size), decoded_frame_history_(max_decode_history) {} diff --git a/modules/video_coding/frame_buffer3_unittest.cc b/modules/video_coding/frame_buffer3_unittest.cc index 786465c92c..b70cd14d63 100644 --- a/modules/video_coding/frame_buffer3_unittest.cc +++ b/modules/video_coding/frame_buffer3_unittest.cc @@ -275,7 +275,8 @@ TEST(FrameBuffer3Test, InterleavedStream) { TEST(FrameBuffer3Test, LegacyFrameIdJumpBehavior) { { - // WebRTC-LegacyFrameIdJumpBehavior is disabled by default. + test::ScopedFieldTrials field_trial( + "WebRTC-LegacyFrameIdJumpBehavior/Disabled/"); FrameBuffer buffer(/*max_frame_slots=*/10, /*max_decode_history=*/100); buffer.InsertFrame(Builder().Time(20).Id(3).AsLast().Build()); @@ -286,8 +287,7 @@ TEST(FrameBuffer3Test, LegacyFrameIdJumpBehavior) { } { - test::ScopedFieldTrials field_trial( - "WebRTC-LegacyFrameIdJumpBehavior/Enabled/"); + // WebRTC-LegacyFrameIdJumpBehavior is disabled by default. FrameBuffer buffer(/*max_frame_slots=*/10, /*max_decode_history=*/100); buffer.InsertFrame(Builder().Time(20).Id(3).AsLast().Build());