Commit graph

6956 commits

Author SHA1 Message Date
Jim Gustafson
99c102adad m126 merge fixes 2024-06-25 14:25:19 -07:00
Jim Gustafson
49c96f3e79 Merge remote-tracking branch 'google/branch-heads/6478' 2024-06-21 16:31:45 -07:00
Jim Gustafson
c43adafcd5 Merge m123/6312 2024-06-12 22:25:35 -07:00
Miriam Zimmerman
84b959dd20
Test fixes
Get webrtc unit tests building again, and fix some failures.
2024-06-11 10:30:46 -04:00
Jim Gustafson
7c9970cacb Remove lbred experiment 2024-06-06 15:10:30 -07:00
Rashad Sookram
c2c56d3d8d
Resolve warnings from delay settings 2024-05-24 12:50:38 -04:00
Jan Grulich
a18e38fed2 Video capture PipeWire: drop corrupted PipeWire buffers
Use SPA_CHUNK_FLAG_CORRUPTED and SPA_META_HEADER_FLAG_CORRUPTED flags to
determine corrupted buffers or corrupted buffer data. We used to only
rely on compositors setting chunk->size, but this doesn't make sense for
dmabufs where they have to make up arbitrary values. It also looks this
is not reliable and can cause glitches as we end up processing corrupted buffers.

(cherry picked from commit cfbd6b0884)

Bug: chromium:341928670
Change-Id: Ida0c6a5e7a37e19598c6d5884726200f81b94962
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/349881
Commit-Queue: Mark Foltz <mfoltz@chromium.org>
Reviewed-by: Mark Foltz <mfoltz@chromium.org>
Reviewed-by: Alexander Cooper <alcooper@chromium.org>
Cr-Original-Commit-Position: refs/heads/main@{#42292}
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/351563
Commit-Queue: Alexander Cooper <alcooper@chromium.org>
Bot-Commit: rubber-stamper@appspot.gserviceaccount.com <rubber-stamper@appspot.gserviceaccount.com>
Cr-Commit-Position: refs/branch-heads/6478@{#1}
Cr-Branched-From: 16fb7903e546051483720548168cd40cded7a040-refs/heads/main@{#42290}
2024-05-23 21:01:17 +00:00
Jeremy Leconte
16fb7903e5 Revert "Provide Environment to construct VideoBitrateAllocator"
This reverts commit 4bf4e1753c.

Reason for revert: break upstream 

Original change's description:
> Provide Environment to construct VideoBitrateAllocator
>
> To allow various VideoBitrateAllocators to use propagated rather than global field trials
>
> Bug: webrtc:42220378
> Change-Id: I52816628169a54b18a4405d84fee69b101f92f72
> Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/349920
> Reviewed-by: Erik Språng <sprang@webrtc.org>
> Reviewed-by: Philip Eliasson <philipel@webrtc.org>
> Commit-Queue: Danil Chapovalov <danilchap@webrtc.org>
> Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
> Cr-Commit-Position: refs/heads/main@{#42288}

Bug: webrtc:42220378
Change-Id: I7d47eb635c2d312d97a870c2a8eca0b23d2f86a0
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/350307
Owners-Override: Jeremy Leconte <jleconte@google.com>
Commit-Queue: Jeremy Leconte <jleconte@google.com>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Bot-Commit: rubber-stamper@appspot.gserviceaccount.com <rubber-stamper@appspot.gserviceaccount.com>
Cr-Commit-Position: refs/heads/main@{#42290}
2024-05-13 13:32:28 +00:00
Danil Chapovalov
4bf4e1753c Provide Environment to construct VideoBitrateAllocator
To allow various VideoBitrateAllocators to use propagated rather than global field trials

Bug: webrtc:42220378
Change-Id: I52816628169a54b18a4405d84fee69b101f92f72
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/349920
Reviewed-by: Erik Språng <sprang@webrtc.org>
Reviewed-by: Philip Eliasson <philipel@webrtc.org>
Commit-Queue: Danil Chapovalov <danilchap@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42288}
2024-05-13 12:12:01 +00:00
Danil Chapovalov
67ba914249 Propagate FieldTrialsView through FEC protection method helpers
And thus in those helpers query RateControlSettings field trials via propagated FieldTrialView instead of the via global field trial string

Bug: webrtc:42220378
Change-Id: I84f4bf42037d864519c4d2031d25cf909fd5010f
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/350305
Commit-Queue: Philip Eliasson <philipel@webrtc.org>
Reviewed-by: Philip Eliasson <philipel@webrtc.org>
Auto-Submit: Danil Chapovalov <danilchap@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42286}
2024-05-13 11:44:26 +00:00
Jakob Ivarsson
28a4ec36a0 Fix use of uninitialized value in NetEq test.
Bug: chromium:339308502
Change-Id: Iee2a6ca190fdd2dee498afa6e36fa0eb1f7dd9b9
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/350304
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Commit-Queue: Jakob Ivarsson‎ <jakobi@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42283}
2024-05-13 09:32:31 +00:00
Lionel Koenig
a656b9d781 Use absolute capture timestamp from the beginning of payload
This ensure the absolute capture timestamp from the first audio sample
encoded in the payload is used for the corresponding rtp header.

Bug: webrtc:42226041
Change-Id: Ib8f2e3a5df5c82c5806171bd5b36a26d92fbea72
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/349265
Commit-Queue: Lionel Koenig <lionelk@webrtc.org>
Reviewed-by: Jakob Ivarsson‎ <jakobi@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42281}
2024-05-13 08:10:56 +00:00
Sergey Silkin
29d4062ff6 Make SpatialLayer to be an alias of SimulcastStream
Bug: b/337757868, b/42234533
Change-Id: I3a5088c2ef64ebc48b37aa51b3ebb7cd395e537b
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/349960
Reviewed-by: Åsa Persson <asapersson@webrtc.org>
Commit-Queue: Sergey Silkin <ssilkin@webrtc.org>
Reviewed-by: Erik Språng <sprang@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42280}
2024-05-13 08:05:19 +00:00
Danil Chapovalov
ac426265b6 Cleanup usage of FieldTrialsView by RateControlSettings and CongestionWindowPushbackController
Replace factory that takes optional FieldTrialView with a constructor that takes non-optional reference to the same interface - all callers already guarantee it is not nullptr
Replace several local IsEnabled/IsDisabled helpers with the same helpers in FieldTrialView
In CongestionWindowPushbackController tests pass field trials bypassing global field trial string

Bug: webrtc:42220378
Change-Id: Ic49ad78919d834a5e3b9b69545d3b39088023a75
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/349900
Commit-Queue: Danil Chapovalov <danilchap@webrtc.org>
Reviewed-by: Erik Språng <sprang@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42270}
2024-05-10 12:40:20 +00:00
Danil Chapovalov
2cdf840b53 Read WebRTC-BweLossExperiment from propagated instead of global field trial
Bug: webrtc:42220378
Change-Id: I4ddb0719aabe89997ba4f2e663515c1b227938ad
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/350301
Reviewed-by: Ying Wang <yinwa@google.com>
Auto-Submit: Danil Chapovalov <danilchap@webrtc.org>
Commit-Queue: Danil Chapovalov <danilchap@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42268}
2024-05-10 10:05:27 +00:00
Sergey Silkin
dbdf36c437 Add key_interval command line argument to codec test
Bug: webrtc:42225151, b/337757868
Change-Id: I5b085bdb334cb6cfb304424a466fc119196d14d4
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/350200
Reviewed-by: Sergey Silkin <ssilkin@webrtc.org>
Reviewed-by: Åsa Persson <asapersson@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Commit-Queue: Sergey Silkin <ssilkin@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42267}
2024-05-10 09:40:18 +00:00
Danil Chapovalov
f20ed3e8ad Add option to provide Environment for CongestionConroller construction
This would allow network controllers, GoogCcNetworkController in particular to have access to Environment at construction and thus it can rely on propagated field trials and won't need to fallback to the global field trial string

Bug: webrtc:42220378
Change-Id: I36099522e3866a89a8c8d6303da03f7d5b1cad8e
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/350201
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Commit-Queue: Danil Chapovalov <danilchap@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42260}
2024-05-08 12:46:23 +00:00
Sergey Silkin
5f3fc5028f Split CreateEncodingSettings
into CreateEncodingSettings and CreateFrameSettings. Also changed bitrate/framerate data types from int/double to DataRate/Frequency.

Bug: webrtc:42225151, b/337757868
Change-Id: I01b8b4e3d34f72250fdb8d64e4ee98ff79bbbd8b
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/349962
Reviewed-by: Åsa Persson <asapersson@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Commit-Queue: Sergey Silkin <ssilkin@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42259}
2024-05-08 11:07:39 +00:00
Mirko Bonadei
fc57037462 Revert "Split digest methods from ssl target into digest target"
This reverts commit 47bfe39ecf.

Reason for revert: Breaks downstream project.

Original change's description:
> Split digest methods from ssl target into digest target
>
> in an attempt to break up the monolithic ssl target.
>
> BUG=None
>
> Change-Id: I38f5b3e2828742d5d918460db1af0a5797d6a5c2
> Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/349764
> Reviewed-by: Harald Alvestrand <hta@webrtc.org>
> Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
> Commit-Queue: Philipp Hancke <phancke@meta.com>
> Cr-Commit-Position: refs/heads/main@{#42249}

Bug: None
Change-Id: Ice6f901cd8c2aecf4cf44d3728ec76568b19a7ca
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/350180
Bot-Commit: rubber-stamper@appspot.gserviceaccount.com <rubber-stamper@appspot.gserviceaccount.com>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Owners-Override: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42255}
2024-05-08 06:42:32 +00:00
Per K
cc92b6e1bd Add ProbeController::EnableRepeatedInitialProbing
This adds a new mode to the ProbeController that sends probes every
second the first 5seconds. Intented usage is before normal media has
started flowing. If enabled, the max allocated bitrat is ignored during
these initial probes.
The purpose is to have a more accurate estimate at the beginning of a
call.
The cl also removes ProbeController::SetFirstProbeToMaxBitrate.

Bug: webrtc:14928
Change-Id: I04feefb2f1b82ff38b35ee2be810f9119c53536a
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/349924
Reviewed-by: Diep Bui <diepbp@webrtc.org>
Commit-Queue: Per Kjellander <perkj@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42252}
2024-05-07 19:37:23 +00:00
Sergey Silkin
f126e8af82 Delete implicit layering mode.
This is a cleanup in VP9 encoder wrapper. The removed code paths were only used in tests. In prod layers are configured explicitly via VideoCodec::spatialLayers[].

Bug: webrtc:42225151
Change-Id: I1de90039488b36e3c88e788c78e675bf2ee68f9b
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/349222
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Auto-Submit: Sergey Silkin <ssilkin@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Ilya Nikolaevskiy <ilnik@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42250}
2024-05-07 16:59:06 +00:00
Philipp Hancke
47bfe39ecf Split digest methods from ssl target into digest target
in an attempt to break up the monolithic ssl target.

BUG=None

Change-Id: I38f5b3e2828742d5d918460db1af0a5797d6a5c2
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/349764
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Commit-Queue: Philipp Hancke <phancke@meta.com>
Cr-Commit-Position: refs/heads/main@{#42249}
2024-05-07 16:52:48 +00:00
Danil Chapovalov
2ee83c1784 Provide Environment for ReceiveSideConfestionController construction
Environment includes propagated field trials that can be later passed to
RemoteBitrateEstimators member, and would allow not to rely on the global field trial string

Bug: webrtc:42220378
Change-Id: Icf75a433c20352b2c22829c2148c92f69a2517aa
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/349645
Commit-Queue: Danil Chapovalov <danilchap@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42242}
2024-05-07 08:02:36 +00:00
Sergey Silkin
f5e9f11994 Delete WebRTC-LibaomAv1Encoder-DisableFrameDropping
This was a kill-switch for frame dropping in AV1 encoder. The frame dropping was enabled in June 2023. Since we have not heard about about any issues related to the frame dropping, we can remove the field trial.

Bug: webrtc:42225542
Change-Id: I4b2f1d5ff61e4ae3a4a7fc6711bb83f7d522fc6a
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/349921
Commit-Queue: Sergey Silkin <ssilkin@webrtc.org>
Reviewed-by: Åsa Persson <asapersson@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42241}
2024-05-07 07:47:32 +00:00
Jakob Ivarsson
1e5f88c5be Make muted param in GetAudio optional.
It is not necessary for the caller to use it and the mute info can be
found on AudioFrame.muted().

Bug: None
Change-Id: I458f1f2e8489c1d8f8a9078b21f889b2540bdab9
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/349940
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Commit-Queue: Jakob Ivarsson‎ <jakobi@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42236}
2024-05-06 18:07:34 +00:00
Sergey Silkin
853e247fbb Set full path to input video in EncodeDecode test
Replaced --video_name with --input_path, --input_width, --input_height and --input_framerate_fps.

Example of command line:
video_codec_perf_tests --input_width=1920 --input_height=1080 --input_framerate_fps=30 --input_path="/full/path/sample.yuv"

Also added y4m source support to the codec tester.

Bug: b/42225151, b/337757868
Change-Id: Ic399b3e819a126e097072c27d74a5fcc0dc1fe6d
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/349581
Commit-Queue: Sergey Silkin <ssilkin@webrtc.org>
Reviewed-by: Åsa Persson <asapersson@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42226}
2024-05-03 17:46:05 +00:00
Philipp Hancke
c14a2cb9cc Add nonstandard x-google-per-layer-pli fmtp for enabling per-layer keyFrames in response to PLIs
which needs to be added to the remote codecs a=fmtp:

This also forces SimulcastCastEncoderAdapter to avoid issues with codecs that have native simulcast capability but do require synchronized keyframes.

This parameter allows for large-scale experimentation and A/B testing
whether the new behavior has advantages. It is to be considered
transitional and may be removed again in the future.

BUG=webrtc:10107

Change-Id: I81f496c987b2fed7ff3089efb746e7e89e89c033
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/333560
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Commit-Queue: Philipp Hancke <phancke@microsoft.com>
Reviewed-by: Ilya Nikolaevskiy <ilnik@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#41805}
2024-05-03 10:59:22 -04:00
Danil Chapovalov
8a5f807313 Reland "h264: bail out early when failing to parse SPS/PPS ids"
This reverts commit e1607ed3a6.

Reason for revert: downstream project adjusted

Original change's description:
> Revert "h264: bail out early when failing to parse SPS/PPS ids"
>
> This reverts commit 4344eb713b.
>
> Reason for revert: Breaks downstream project.
>
> Original change's description:
> > h264: bail out early when failing to parse SPS/PPS ids
> >
> > This currently gets caught later in the process by the H264 SPS/PPS
> > tracker but can be rejected explicitly here. The network observable
> > behavior should be similar and request a key frame after a 200ms delay, at least for entities that send such bad bitstreams
> >
> > BUG=webrtc:337076010
> >
> > Change-Id: I239c64efa7db631460ef9e9986d283335303df5f
> > Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/349060
> > Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
> > Reviewed-by: Harald Alvestrand <hta@webrtc.org>
> > Commit-Queue: Philipp Hancke <phancke@meta.com>
> > Cr-Commit-Position: refs/heads/main@{#42211}
>
> Bug: webrtc:337076010
> Change-Id: I15b815c69f1d25e41fb222d46359655242589fba
> No-Presubmit: true
> No-Tree-Checks: true
> No-Try: true
> Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/349661
> Bot-Commit: rubber-stamper@appspot.gserviceaccount.com <rubber-stamper@appspot.gserviceaccount.com>
> Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
> Owners-Override: Mirko Bonadei <mbonadei@webrtc.org>
> Cr-Commit-Position: refs/heads/main@{#42217}

Bug: webrtc:337076010
Change-Id: Ibe5a960b9b5fdf9a35e5dfffb47b78ade36b0cec
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/349700
Bot-Commit: rubber-stamper@appspot.gserviceaccount.com <rubber-stamper@appspot.gserviceaccount.com>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Commit-Queue: Danil Chapovalov <danilchap@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42223}
2024-05-03 11:33:45 +00:00
Danil Chapovalov
111d957ada Cleanup unused field trial WebRTC-Video-BandwidthQualityScalerSettings
Bug: webrtc:42221607, webrtc:42223115
Change-Id: I6eda70ce7c3e914f57fe1a70f33891a5742d985b
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/349482
Reviewed-by: Erik Språng <sprang@webrtc.org>
Commit-Queue: Danil Chapovalov <danilchap@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42220}
2024-05-03 10:02:00 +00:00
Evan Shrubsole
5b643294af Use proper TRACE_EVENT_ASYNC_STEP macro with perfetto
There is no TRACE_EVENT_ASYNC_STEP in the perfetto legacy API.
The corresponding legacy API that matches best is
TRACE_EVENT_ASYNC_STEP_INTO.

Bug: b/42226290
Change-Id: I6725973895878e34d96b6cd3314ab8de402a911b
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/349120
Reviewed-by: Erik Språng <sprang@webrtc.org>
Commit-Queue: Evan Shrubsole <eshr@google.com>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42219}
2024-05-03 09:08:28 +00:00
Sergey Silkin
8410b6e9e6 Add --screencast and --frame_drop flags to EncodeDecode test
Bug: b/42225151, b/337757868
Change-Id: I78c053cb47961ff86c001be3150dc1efb13870af
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/349481
Commit-Queue: Sergey Silkin <ssilkin@webrtc.org>
Reviewed-by: Erik Språng <sprang@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42218}
2024-05-03 09:04:39 +00:00
Mirko Bonadei
e1607ed3a6 Revert "h264: bail out early when failing to parse SPS/PPS ids"
This reverts commit 4344eb713b.

Reason for revert: Breaks downstream project.

Original change's description:
> h264: bail out early when failing to parse SPS/PPS ids
>
> This currently gets caught later in the process by the H264 SPS/PPS
> tracker but can be rejected explicitly here. The network observable
> behavior should be similar and request a key frame after a 200ms delay, at least for entities that send such bad bitstreams
>
> BUG=webrtc:337076010
>
> Change-Id: I239c64efa7db631460ef9e9986d283335303df5f
> Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/349060
> Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
> Reviewed-by: Harald Alvestrand <hta@webrtc.org>
> Commit-Queue: Philipp Hancke <phancke@meta.com>
> Cr-Commit-Position: refs/heads/main@{#42211}

Bug: webrtc:337076010
Change-Id: I15b815c69f1d25e41fb222d46359655242589fba
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/349661
Bot-Commit: rubber-stamper@appspot.gserviceaccount.com <rubber-stamper@appspot.gserviceaccount.com>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Owners-Override: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42217}
2024-05-03 08:02:31 +00:00
Per K
363917a1dd Add support for receiving CongestionControlFeedback to RTCPReceiver
Support for parsing the packet is gated behind field trial
WebRTC-RFC8888CongestionControlFeedback/Enabled/.

Bug: webrtc:15368
Change-Id: Ib4478e821fe5a43510af5131543e7861cf54d901
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/348664
Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
Commit-Queue: Per Kjellander <perkj@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42215}
2024-05-02 21:01:38 +00:00
Philipp Hancke
4344eb713b h264: bail out early when failing to parse SPS/PPS ids
This currently gets caught later in the process by the H264 SPS/PPS
tracker but can be rejected explicitly here. The network observable
behavior should be similar and request a key frame after a 200ms delay, at least for entities that send such bad bitstreams

BUG=webrtc:337076010

Change-Id: I239c64efa7db631460ef9e9986d283335303df5f
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/349060
Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Commit-Queue: Philipp Hancke <phancke@meta.com>
Cr-Commit-Position: refs/heads/main@{#42211}
2024-05-02 16:15:18 +00:00
Per K
d48a18fbbb Limit pacingfactor by upper link capacity estimate.
If pacing rate, (current loss based bwe * pacing factor) is larger than the current upper link capacity estimate, reduce pacing factor to max of current bwe and upper link capacity.

Bug: webrtc:42220543
Change-Id: I5246da1f38530f8d411e7314adaa8651fc848f48
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/349601
Reviewed-by: Diep Bui <diepbp@webrtc.org>
Commit-Queue: Per Kjellander <perkj@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42210}
2024-05-02 15:13:56 +00:00
Per K
55f6613fc0 Retry initial probe if it times out and BWE has not been updated.
This is to avoid the case where the initial probe fail and the BWE is not updated, which can lead to a long period of low bandwidth.

Bug: webrtc:14928
Change-Id: Ie8f84270507b59995d57e4ab6e2a984570191529
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/349580
Commit-Queue: Per Kjellander <perkj@webrtc.org>
Reviewed-by: Diep Bui <diepbp@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42208}
2024-05-02 12:42:32 +00:00
Jesús de Vicente Peña
eeff850106 Adding the option to experiment with the max_allowed_excess_render_blocks parameter.
Bug: webrtc:337900458
Change-Id: I2108c7c67eb9aa460932efe881760924109b1915
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/349460
Reviewed-by: Per Åhgren <peah@webrtc.org>
Commit-Queue: Jesus de Vicente Pena <devicentepena@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42207}
2024-05-02 12:20:23 +00:00
Philipp Hancke
acfd279a14 av1: make packetization generate more evenly sized packets
Implements a two-pass approach to packetization which creates
packets of an even size similar to RtpPacketizer::SplitAboutEqually.
This improves the bandwidth estimation.

The algorithm does a first pass with the existing packetizer, then
iterates through the resulting packet sizes and sums up the bytes left unused in each packet.
It then calculates a new maximum packet length as
  configured_max_packet_len - ((unused_bytes - packets + 1) / packets)
adjusts for the overhead and re-runs the packetization algorithm.

For example, a list of OBUs with sizes
  {1206, 1476, 1431}
currently gets packetized greedily as payload sizes
  {1200, 1200, 1200, 523}
With this change, it gets packetized as
  {1032, 1032, 1032, 1028}

This change is guarded by the field trial
  WebRTC-Video-AV1EvenPayloadSizes
which is acting as a rollout flag.

BUG=webrtc:15927

Co-authored-by: Shyam Sadhwani <shyamsadhwani@meta.com>
Change-Id: I4f0b3c27de6f06104908dd769c4dd1f34115712c
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/348100
Commit-Queue: Philipp Hancke <phancke@meta.com>
Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
Reviewed-by: Per Kjellander <perkj@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42203}
2024-04-30 15:46:06 +00:00
Tommi
1f3679884c Start using ArrayView in AudioFrame, update PushResampler
Start introducing ArrayView to AudioFrame and code that flows down
from there.  In this first step:
* Add `data_view()` that returns a read-only ArrayView for the
  audio buffer. When AudioFrame is not initialized however, data_view()
  will return a nullptr whereas the current data() method never returns
  nullptr.
* Add `mutable_data()` that requires two arguments for properly setting
  the samples per channel and number of channels that's required for
  accurately reserving the returned mutable ArrayView.
  A notable behavior change is that if the requested number of channels
  is larger than supported or the calculated buffer size is too large,
  the function will trigger a check.
* Add TODOs for following work.

Bug: chromium:335805780
Change-Id: I2937de800422589ebe6a3840b3caadf3d9ff8b00
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/347982
Reviewed-by: Per Åhgren <peah@webrtc.org>
Commit-Queue: Tomas Gunnarsson <tommi@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42202}
2024-04-30 15:33:08 +00:00
Danil Chapovalov
652bd288b3 Query EncoderInfoSettings through propagated field trials
Instead of from the global field trial string.

Bug: webrtc:42220378
Change-Id: Iddb41429e388792de02f702b4caa35689c57d9e5
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/347720
Reviewed-by: Erik Språng <sprang@webrtc.org>
Commit-Queue: Danil Chapovalov <danilchap@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42201}
2024-04-30 11:16:31 +00:00
Tommi
b2b6166dc4 Make AudioFrame::channel_layout_ private and check for valid values
Bug: chromium:335805780
Change-Id: Ida671d317c07983cc51faa1a498642747dbb810c
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/349322
Reviewed-by: Per Åhgren <peah@webrtc.org>
Commit-Queue: Tomas Gunnarsson <tommi@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42199}
2024-04-30 11:02:40 +00:00
Evan Shrubsole
cd09858f4a Convert decoder TRACE_EVENT to flows
This is the first new style trace event so this CL adds and updates
WebRTCs Perfetto configuration.

* Changes all #includes to target "third_party/perfetto". Added this
to DEPS.
* Expose the Perfetto public config in the "tracing" group using
an all_dependent_configs statement. This means the config is included
in all parts that include the "//:tracing" group. However, direct
perfetto includes are banned per DEPS.
* In order to expose Perfetto types (ie Flow/TerminatingFlow) the
perfetto headers are a dependancy on all targets. This should not
affect binary size as these are not used when perfetto is not enabled
and will not be linked.

Bug: b/42226290
Change-Id: I5711d81dae95ee907cbcd41bf1ee9b55d2ec595c
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/349161
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Commit-Queue: Evan Shrubsole <eshr@google.com>
Cr-Commit-Position: refs/heads/main@{#42197}
2024-04-30 08:47:29 +00:00
Jesús de Vicente Peña
3703b3500c Using Ntp times for the absolute send time.
Bug: webrtc:15930
Change-Id: Ie460ac6e3561efafeb11bf36735cb6f33bdfd8a3
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/349162
Commit-Queue: Jesus de Vicente Pena <devicentepena@webrtc.org>
Reviewed-by: Jakob Ivarsson‎ <jakobi@webrtc.org>
Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
Reviewed-by: Lionel Koenig Gélas <lionelk@google.com>
Cr-Commit-Position: refs/heads/main@{#42183}
2024-04-26 12:59:09 +00:00
memetao
decc48fd97 Fix 'Screen flickering on ScreenCapturerWinDirectx'
Bug: webrtc:15718
Change-Id: I230a0a7d196a4a3aea3b3e47cdf4f47c437e7196
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/330800
Commit-Queue: Mark Foltz <mfoltz@chromium.org>
Reviewed-by: Zijie He <zijiehe@chromium.org>
Reviewed-by: Mark Foltz <mfoltz@chromium.org>
Cr-Commit-Position: refs/heads/main@{#42177}
2024-04-25 21:18:27 +00:00
Danil Chapovalov
e92b143eea Remove VideoCodingModule dependency on the global field trial string
Environment provides non-null interface for FieldTrialsView and thus VideoCodingModule no longer need to rely on FieldTrialBasedConfig class to provide field_trials when not passed at construction.

Bug: webrtc:10335
Change-Id: Iedfb29e8b29056618a85f2e7a1528da29e3be5c1
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/347701
Auto-Submit: Danil Chapovalov <danilchap@webrtc.org>
Reviewed-by: Philip Eliasson <philipel@webrtc.org>
Commit-Queue: Philip Eliasson <philipel@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42163}
2024-04-24 17:39:03 +00:00
Jakob Ivarsson
00a8839d47 Allow source tracker to be called synchronously on a single thread.
Bug: None
Change-Id: I699c0c787d28fe79959e93b3e1eda2634c931cef
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/348840
Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
Commit-Queue: Jakob Ivarsson‎ <jakobi@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42154}
2024-04-23 14:31:46 +00:00
Danil Chapovalov
54dec3f3d7 Delete deprecated variants for parsing/building AudioLevelExtension
Bug: webrtc:15788
Change-Id: I37034b9b1daf7b26dd5e66156e71c63e2fb85b21
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/345520
Auto-Submit: Danil Chapovalov <danilchap@webrtc.org>
Commit-Queue: Åsa Persson <asapersson@webrtc.org>
Reviewed-by: Åsa Persson <asapersson@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42152}
2024-04-23 12:57:51 +00:00
Evan Shrubsole
5bfcc873d9 Add event scope to all TRACE_EVENT_INSTANTs
These are required by the Perfetto API and the missing argument prevents
the use of Perfetto.

Bug: webrtc:15917
Change-Id: Ie40c0344dc9d8cd40f7c751b133d150b975a33c7
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/347702
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Tomas Gunnarsson <tommi@webrtc.org>
Commit-Queue: Evan Shrubsole <eshr@google.com>
Cr-Commit-Position: refs/heads/main@{#42147}
2024-04-23 09:56:33 +00:00
Per K
86298f7a84 Implementation of RFC 8888 TranportLayerFeedback RTCP packet
This cl adds an implementation of the RTCP feedback packet as specified in https://www.rfc-editor.org/rfc/rfc8888.html

Bug: webrtc:15368
Change-Id: I0b9a7fb15512ff9f9e721efd8e03ebe981a8d9bd
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/347901
Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
Commit-Queue: Per Kjellander <perkj@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42140}
2024-04-22 14:41:42 +00:00
Florent Castelli
f4673f97ed Move webrtc::AudioDeviceModule include to api/ folder
Bug: webrtc:15874
Change-Id: I5bdb19d5e710838b41e6ca283d406c9f1f21286b
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/348060
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Reviewed-by: Henrik Andreassson <henrika@webrtc.org>
Commit-Queue: Florent Castelli <orphis@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42137}
2024-04-22 08:56:31 +00:00