7267 Commits

Author SHA1 Message Date
Per Kjellander
776866774f Propagate desicion if RTP packet should be ECT(1) marked to socket
With this CL, the decision if an RTP packet should be sent as ect(1) is made in RtpControllerSend depending on if RFC 8888 has been negotiated and if CCFB is received with ECN enabled.
Since webrtc does not yet adapt to ECN feedback, packets are sent as ECT(1) until the first feedback is received.

Change-Id: Iddf63849328afbe54a7c8f921f2e8db134aeff6a
Bug: webrtc:42225697
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/367388
Commit-Queue: Per Kjellander <perkj@webrtc.org>
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43609}
2024-12-19 01:59:49 -08:00
Danil Chapovalov
8da0652263 Switch to injected field trials in GainController2
Bug: webrtc:369904700
Change-Id: I28dc43ffe4f1edaf55a5be05371618cbb76d0709
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/371660
Reviewed-by: Sam Zackrisson <saza@webrtc.org>
Commit-Queue: Danil Chapovalov <danilchap@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43596}
2024-12-18 02:39:19 -08:00
Shunbo Li
6f866347ff Fix H26xPacketBuffer Behavior Changes for Padding Packets
This commit fixes the issue of H26xPacketBuffer not supporting the
 RTP padding packet.

Bug: webrtc:383841353
Change-Id: Ibd87cd9c18577d990fa56a2fdfed1552d33b58a2
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/371840
Reviewed-by: Sergey Silkin <ssilkin@webrtc.org>
Reviewed-by: Erik Språng <sprang@webrtc.org>
Commit-Queue: Sergey Silkin <ssilkin@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43586}
2024-12-17 03:35:55 -08:00
Takuto Ikuta
5c5bb5b099 add missing includes for the build with use_libcxx_modules
This is to fix build error when we set use_libcxx_modules=true in
chromium build.

Bug: chromium:40440396
Change-Id: Iad165a78a6920ccb858567d31fbe5e48d8a7b629
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/371620
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Auto-Submit: Takuto Ikuta <tikuta@google.com>
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43574}
2024-12-16 01:47:31 -08:00
Danil Chapovalov
4c73d1a326 Starting using propagated field trials in the AudioProcessingImpl
Bug: webrtc:369904700
Change-Id: Ibc9a2e5349f0d1ba7a7a7ebdd57dfddaf092a1af
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/368520
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Commit-Queue: Danil Chapovalov <danilchap@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43564}
2024-12-13 11:05:17 -08:00
Danil Chapovalov
3e98919a6a Reland "Validate frame consistency when writing DependencyDescriptor"
This reverts commit 81aa059b85949001dabbedaaf99574dc6390882f.

Reason for revert: downstream tests fixed

Original change's description:
> Revert "Validate frame consistency when writing DependencyDescriptor"
>
> This reverts commit 200fd82771ae29d23b2be40194be674b3437f0ab.
>
> Reason for revert: breaks downstream
>
> Original change's description:
> > Validate frame consistency when writing DependencyDescriptor
> >
> > To write DependencyDescriptor frame properties should be consistent with
> > the FrameDependencyStructure.
> > Historically that was ensured by webrtc codec wrappers, but with with frame transform api interface there are now more ways to inject video frame for packetizing.
> > Thus DependencyDescriptorWriter should be more protective to avoid crashes.
> >
> > Bug: chromium:379282549
> > Change-Id: I98f226ff09c32154e18888c8e811e7981567ad45
> > Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/371301
> > Commit-Queue: Danil Chapovalov <danilchap@webrtc.org>
> > Reviewed-by: Åsa Persson <asapersson@webrtc.org>
> > Cr-Commit-Position: refs/heads/main@{#43551}
>
> Bug: chromium:379282549
> Change-Id: I7711756f774648cbb85c51b61424bb950c1d3775
> No-Presubmit: true
> No-Tree-Checks: true
> No-Try: true
> Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/371420
> Commit-Queue: Jeremy Leconte <jleconte@webrtc.org>
> Owners-Override: Jeremy Leconte <jleconte@webrtc.org>
> Bot-Commit: rubber-stamper@appspot.gserviceaccount.com <rubber-stamper@appspot.gserviceaccount.com>
> Cr-Commit-Position: refs/heads/main@{#43556}

Bug: chromium:379282549
Change-Id: I71ef363d710b7f28b298d11543e1c8ad6c884f15
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/371304
Bot-Commit: rubber-stamper@appspot.gserviceaccount.com <rubber-stamper@appspot.gserviceaccount.com>
Reviewed-by: Erik Språng <sprang@webrtc.org>
Commit-Queue: Danil Chapovalov <danilchap@webrtc.org>
Reviewed-by: Jeremy Leconte <jleconte@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43563}
2024-12-13 10:17:33 -08:00
Danil Chapovalov
29a3f928f9 In PacketBuffer do not attempt to clear before 1st packet
ClearTo logic relies on clear to sequence number follows first_seq_num_

Bug: chromium:370689424
Change-Id: I12874d5ce7adfdcf9c0691acacdd2b8ae41ce307
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/371320
Commit-Queue: Danil Chapovalov <danilchap@webrtc.org>
Reviewed-by: Rasmus Brandt <brandtr@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43558}
2024-12-13 04:27:19 -08:00
Jeremy Leconte
81aa059b85 Revert "Validate frame consistency when writing DependencyDescriptor"
This reverts commit 200fd82771ae29d23b2be40194be674b3437f0ab.

Reason for revert: breaks downstream

Original change's description:
> Validate frame consistency when writing DependencyDescriptor
>
> To write DependencyDescriptor frame properties should be consistent with
> the FrameDependencyStructure.
> Historically that was ensured by webrtc codec wrappers, but with with frame transform api interface there are now more ways to inject video frame for packetizing.
> Thus DependencyDescriptorWriter should be more protective to avoid crashes.
>
> Bug: chromium:379282549
> Change-Id: I98f226ff09c32154e18888c8e811e7981567ad45
> Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/371301
> Commit-Queue: Danil Chapovalov <danilchap@webrtc.org>
> Reviewed-by: Åsa Persson <asapersson@webrtc.org>
> Cr-Commit-Position: refs/heads/main@{#43551}

Bug: chromium:379282549
Change-Id: I7711756f774648cbb85c51b61424bb950c1d3775
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/371420
Commit-Queue: Jeremy Leconte <jleconte@webrtc.org>
Owners-Override: Jeremy Leconte <jleconte@webrtc.org>
Bot-Commit: rubber-stamper@appspot.gserviceaccount.com <rubber-stamper@appspot.gserviceaccount.com>
Cr-Commit-Position: refs/heads/main@{#43556}
2024-12-13 00:19:47 -08:00
Danil Chapovalov
1bb49e9ad4 Delete deprecated AudioProcessingBuilder
BuiltinAudioProcessingBuilder should be used instead.
This would allow AudioProcessingImpl to have Environment construction parameter and thus use propagated rather than global field trials.

Bug: webrtc:369904700
Change-Id: I4fcc299bb9e65c109a3fe476c755a81c2aea551c
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/368480
Commit-Queue: Danil Chapovalov <danilchap@webrtc.org>
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43553}
2024-12-12 12:50:56 -08:00
Danil Chapovalov
200fd82771 Validate frame consistency when writing DependencyDescriptor
To write DependencyDescriptor frame properties should be consistent with
the FrameDependencyStructure.
Historically that was ensured by webrtc codec wrappers, but with with frame transform api interface there are now more ways to inject video frame for packetizing.
Thus DependencyDescriptorWriter should be more protective to avoid crashes.

Bug: chromium:379282549
Change-Id: I98f226ff09c32154e18888c8e811e7981567ad45
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/371301
Commit-Queue: Danil Chapovalov <danilchap@webrtc.org>
Reviewed-by: Åsa Persson <asapersson@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43551}
2024-12-12 08:54:04 -08:00
Fanny Linderborg
3a1f2e6a69 Delete FrameToRender from VCMReceiveCallback
The `FrameToRender` method is deprecated and has been replaced by
`OnFrameToRender`.

Bug: webrtc:358039777
Change-Id: Ibe56bd43cf045d814137ba8c4374bc9b9ce8ef6c
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/371302
Commit-Queue: Fanny Linderborg <linderborg@webrtc.org>
Reviewed-by: Erik Språng <sprang@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43547}
2024-12-12 07:34:08 -08:00
Takuto Ikuta
000f04375b add missing includes for the build with use_libcxx_modules
This is to fix build error when we set use_libcxx_modules=true in
chromium build.

Bug: chromium:40440396
Change-Id: I5ab1cfcc0d060021892aae0e5ff3f0b647ae4266
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/370860
Commit-Queue: Takuto Ikuta <tikuta@google.com>
Reviewed-by: Stefan Holmer <stefan@webrtc.org>
Reviewed-by: Tomas Gunnarsson <tommi@webrtc.org>
Auto-Submit: Takuto Ikuta <tikuta@google.com>
Cr-Commit-Position: refs/heads/main@{#43541}
2024-12-11 17:32:19 -08:00
Jiewei Qian
4ef6ddd980 ssci: mark fft as "canonical"
Based on the description, this dependency have no meaningful upstream,
and is maintained inside webrtc.

Marking this dependency's URL to indicate the webrtc's repo is the
canonical repo.

Fixed: chromium:362397270
Change-Id: If6e16a6e34e0083be31d4436fcdfa7c83cd9179a
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/370980
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Commit-Queue: Tomas Gunnarsson <tommi@webrtc.org>
Auto-Submit: Jiewei Qian <qjw@google.com>
Reviewed-by: Tomas Gunnarsson <tommi@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43535}
2024-12-11 10:53:06 +00:00
Harald Alvestrand
50387647ec Update fft/README.chromium to conform to guidelines.
No-Try: true
Bug: webrtc:42234774, chromium:362397270
Change-Id: Id8d7368ded541b2bc31b53fc86158c366bf1d57d
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/370842
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43524}
2024-12-10 09:14:48 +00:00
Sergey Silkin
93f5f9e867 Restrict max number of threads in dav1d settings
Dav1d expects Dav1dSettings::n_threads to be in range [0,256]. http://google3/third_party/dav1d/src/lib.c;l=130;rcl=674317898

Bug: none
Change-Id: I4a7dfd15be733b84809aa1fc496b261d097ca5e7
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/370800
Reviewed-by: Åsa Persson <asapersson@webrtc.org>
Commit-Queue: Sergey Silkin <ssilkin@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43516}
2024-12-09 13:55:13 +00:00
Per Kjellander
15543544b9 Test that caller adapts to link capacity using CCFB
Fix todo to ensure TransportSequence numbers are generated if CCFB according to RFC 8888 is used. Transport sequence numbers are used in BWE algorithms regardless of feedback format.

Bug: webrtc:42225697
Change-Id: I6eab95c0241d590f6e7a90d19c82d13ab8692f2b
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/370341
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Commit-Queue: Per Kjellander <perkj@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43515}
2024-12-09 11:35:03 +00:00
Erik Språng
4c56c9ff9a Add helper class for determining ACD filter settings.
Further, add use of it in libvpx_vp8_encoder and with tuning for keyframes and lower bound of std_dev = 1.25 to work around some edge cases. Plus some minor cleanup.

Bug: webrtc:358039777
Change-Id: I6f624a6a8c7ccfe2fe656e4c089c225296f0264f
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/370061
Reviewed-by: Sergey Silkin <ssilkin@webrtc.org>
Commit-Queue: Erik Språng <sprang@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43513}
2024-12-09 10:21:43 +00:00
Björn Terelius
711e1a8beb Create a custom test launcher for android
Set use_default_launcher=false in rtc_test on android

Bug: webrtc:42223878
Change-Id: If05da40b420d5da8f9e0f39560eb07380ebada14
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/368921
Owners-Override: Jeremy Leconte <jleconte@webrtc.org>
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Reviewed-by: Jeremy Leconte <jleconte@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Commit-Queue: Jeremy Leconte <jleconte@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43505}
2024-12-06 09:30:37 +00:00
Per K
ae1ad04077 Add support for receiving congestion control messages to rtcp transceiver
Congestion control feedback messages follow RFC 8888.

BUG: webrtc:42225697
Change-Id: If7e55249ac479636c0bab5cbcf96e70c1976a51d
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/370161
Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
Commit-Queue: Per Kjellander <perkj@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43486}
2024-12-03 16:55:20 +00:00
Harald Alvestrand
10c7d73688 Fix sign error in UMA for AbsCapture.Delta
Bug: webrtc:380712819
Change-Id: Icfb42f0455718058a54391e5a586f409cd28728d
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/370000
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Reviewed-by: Johannes Kron <kron@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43481}
2024-12-03 02:24:53 +00:00
Philipp Hancke
b0be928a50 Cleanup H264 packetization unit tests
improve consistency, formatting and style

BUG=None

Change-Id: Iad382d9a7194b0606c1aa9c7d264dfacf03cde1f
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/369462
Reviewed-by: Sergey Silkin <ssilkin@webrtc.org>
Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
Commit-Queue: Philipp Hancke <phancke@meta.com>
Cr-Commit-Position: refs/heads/main@{#43479}
2024-12-02 17:43:16 +00:00
Erik Språng
5fc7489aa0 Fix corruption score not being calculated on higher spatial layers.
This is a re-upload of
https://webrtc-review.googlesource.com/c/src/+/369020

Bug: webrtc:358039777
Change-Id: I7456940965084d0ce55b29b3b9bc98162cfff948
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/369862
Reviewed-by: Sergey Silkin <ssilkin@webrtc.org>
Commit-Queue: Erik Språng <sprang@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43478}
2024-12-02 14:46:45 +00:00
Harald Alvestrand
56c5507ae3 Fix delta computation in abs-capture statistics
Previous computation assumed that local clock is UTC. It isn't.
Adding integration test for abs-capture stats.

Bug: webrtc:380712819
Change-Id: I054d61984cbd017b7ad04ab13e5a687eab89db69
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/369421
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Reviewed-by: Johannes Kron <kron@webrtc.org>
Reviewed-by: Tomas Gunnarsson <tommi@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43465}
2024-11-27 16:17:21 +00:00
Danil Chapovalov
e0a524b5e0 Add default constructor to relative units types
0 is natural default value for types that can be accumulated
Having default constructor simplify usage of these types in templated code.

Bug: None
Change-Id: If005c69018a2a11011bc789502fdbc600cad3278
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/369440
Reviewed-by: Per Kjellander <perkj@webrtc.org>
Commit-Queue: Danil Chapovalov <danilchap@webrtc.org>
Commit-Queue: Per Kjellander <perkj@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43460}
2024-11-26 17:59:08 +00:00
Harald Alvestrand
e9193d7031 Add histograms for Abs-Capture-Timestamp
Bug: webrtc:380712819
Change-Id: I5f56caffe33a257432551321f7c097c852b134dd
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/368903
Reviewed-by: Johannes Kron <kron@webrtc.org>
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43458}
2024-11-26 13:41:36 +00:00
Jakob Ivarsson
ff88950833 Reland "Add InsertPacket method that takes RtpPacketInfo."
This is a reland of commit 38ddea5ee3320bf3441aeb3654e099b3695c9789

Original change's description:
> Add InsertPacket method that takes RtpPacketInfo.
>
> The version which only passes receive_time will be removed (once migrated).
> Keeping the version that only passes header and payload for convenience.
>
> This will allow us to attach more metadata on the worker thread before InsertPacket, instead of on the playout thread after GetAudio. Eventually, the plan is to split the RTP handling on the worker thread into a separate class.
>
> Bug: webrtc:42223109
> Change-Id: I5399b53b9fc5c2f1c996e109054b1b0877ecca05
> Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/369000
> Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
> Commit-Queue: Jakob Ivarsson‎ <jakobi@webrtc.org>
> Cr-Commit-Position: refs/heads/main@{#43445}

Bug: webrtc:42223109
Change-Id: I97d1d3d390e6d3de8bf9355b895ec336339d079f
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/369260
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Commit-Queue: Jakob Ivarsson‎ <jakobi@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43454}
2024-11-26 09:42:11 +00:00
Philipp Hancke
b7cb8fe75a h264: skip empty NAL units, do not reject them
BUG=webrtc:380291923

Change-Id: If05268bde2ac0c600dcef479c88ca54dce708dcb
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/368893
Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
Reviewed-by: Sergey Silkin <ssilkin@webrtc.org>
Commit-Queue: Philipp Hancke <phancke@meta.com>
Cr-Commit-Position: refs/heads/main@{#43451}
2024-11-26 03:55:09 +00:00
Jakob Ivarsson‎
a08189b948 Revert "Add InsertPacket method that takes RtpPacketInfo."
This reverts commit 38ddea5ee3320bf3441aeb3654e099b3695c9789.

Reason for revert: not backwards compatible

Original change's description:
> Add InsertPacket method that takes RtpPacketInfo.
>
> The version which only passes receive_time will be removed (once migrated).
> Keeping the version that only passes header and payload for convenience.
>
> This will allow us to attach more metadata on the worker thread before InsertPacket, instead of on the playout thread after GetAudio. Eventually, the plan is to split the RTP handling on the worker thread into a separate class.
>
> Bug: webrtc:42223109
> Change-Id: I5399b53b9fc5c2f1c996e109054b1b0877ecca05
> Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/369000
> Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
> Commit-Queue: Jakob Ivarsson‎ <jakobi@webrtc.org>
> Cr-Commit-Position: refs/heads/main@{#43445}

Bug: webrtc:42223109
Change-Id: Ie7cf397cfbe5dedca009f16e5e9e3af40adbe99b
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/369200
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Bot-Commit: rubber-stamper@appspot.gserviceaccount.com <rubber-stamper@appspot.gserviceaccount.com>
Commit-Queue: Jakob Ivarsson‎ <jakobi@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43450}
2024-11-25 15:25:10 +00:00
Per Kjellander
06723eaab8 Default max limit probe to 2x current bwe
If max allocated bitrate change, default max limit probe to 2x current
BWE.

Bug: webrtc:369044000, b/370883514
Change-Id: Ibaf79fff94157186002728828d6574bea21afd24
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/368820
Commit-Queue: Per Kjellander <perkj@webrtc.org>
Reviewed-by: Diep Bui <diepbp@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43448}
2024-11-25 11:33:03 +00:00
Jakob Ivarsson
38ddea5ee3 Add InsertPacket method that takes RtpPacketInfo.
The version which only passes receive_time will be removed (once migrated).
Keeping the version that only passes header and payload for convenience.

This will allow us to attach more metadata on the worker thread before InsertPacket, instead of on the playout thread after GetAudio. Eventually, the plan is to split the RTP handling on the worker thread into a separate class.

Bug: webrtc:42223109
Change-Id: I5399b53b9fc5c2f1c996e109054b1b0877ecca05
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/369000
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Commit-Queue: Jakob Ivarsson‎ <jakobi@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43445}
2024-11-22 17:01:01 +00:00
Alessio Bazzica
cd013b1d59 Opus decoder: stereo decoding by default (behind field trial)
- Add `WebRTC-Audio-OpusDecodeStereoByDefault` field trial
- Behind that field trial, `AudioDecoderOpus::SdpToConfig` uses 2
  instead of 1 as default number of channels when the `stereo` codec
  param is unspecified
- Instead of wiring up `FieldTrialsView` to `SdpToConfig`, which
  requires API changes that break downstream projects, a change in
  `AudioDecoderOpus::Config` is made to signal when the number of
  channels is forced via SDP config

Bug: webrtc:379996136
Change-Id: If70eb19bc7e3bc74dd0423610cb04ae33ea602fe
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/368860
Commit-Queue: Alessio Bazzica <alessiob@webrtc.org>
Reviewed-by: Tomas Gunnarsson <tommi@webrtc.org>
Reviewed-by: Jakob Ivarsson‎ <jakobi@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43440}
2024-11-22 07:37:10 +00:00
Olov Brändström
1b0371a54e Reduce the moving median window size in Remote ntp time estimator.
Too big median window will cause errors with large clock drifts, since we'll end up using old values for estimated clock drift.

If the window is too small, the remote clock offset estimation could be noisy or we could even end up using outliers as the offset estimation.

I will not claim that I choose the correct value, and I'm not sure how  to measure the quality of the remote clock offset estimations.

Bug: webrtc:379809147
Change-Id: Ib317548d3eec74105d468ef53830e12eb114df7d
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/368580
Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
Reviewed-by: Ilya Nikolaevskiy <ilnik@webrtc.org>
Commit-Queue: Olov Brändström <brandstrom@google.com>
Cr-Commit-Position: refs/heads/main@{#43439}
2024-11-22 07:36:06 +00:00
林恩
253b8464ff Fix AV1 encoder do't set end_of_picture when the top layer is dropped
Bug: webrtc:357721007
Change-Id: I4e318618192aa9d58a2ef6338f7b1e2ee5140254
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/366100
Reviewed-by: Åsa Persson <asapersson@webrtc.org>
Commit-Queue: Sergey Silkin <ssilkin@webrtc.org>
Reviewed-by: Sergey Silkin <ssilkin@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43437}
2024-11-21 18:56:16 +00:00
Dor Hen
da7b7ca1c1 Comment unused variables in implemented functions 15\n
Bug: webrtc:370878648
Change-Id: I4529c17f54c653864cca27097e44c843210b9c52
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/368061
Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
Commit-Queue: Dor Hen <dorhen@meta.com>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43429}
2024-11-20 11:50:20 +00:00
Tommi
5f163fcaa0 Align Int16FrameData test class with AudioFrame
This updates test code that tests interleaved audio frames to use
some of the same properties and types as AudioFrame (rather than copy).

The CL also moves code from audio_processing_unittest.cc that modifies
the buffer owned by Int16FrameData, into Int16FrameData.

Bug: none
Change-Id: Iab37227deb302bf4fc832633d312262e5249caad
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/355960
Reviewed-by: Per Åhgren <peah@webrtc.org>
Commit-Queue: Tomas Gunnarsson <tommi@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43424}
2024-11-19 12:14:15 +00:00
Per K
8337c966d4 Use default probe duration if target higher than networkstate estimate
Use default probe duration and probe delta if probe target higher than
network state estimate.


Bug: webrtc:42224658, b/379234056
Change-Id: I1e6283681d005111fce5fc90e468b1ce2ce4b81f
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/368620
Commit-Queue: Per Kjellander <perkj@webrtc.org>
Reviewed-by: Diep Bui <diepbp@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43423}
2024-11-19 11:13:15 +00:00
Alessio Bazzica
4c9dbd508d Remove/update TODOs assigned to alessiob
Bug: webrtc:379542219
Change-Id: I1da54a9a13187d9e7d836dd4e1a85e49b685d971
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/368540
Commit-Queue: Alessio Bazzica <alessiob@webrtc.org>
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43420}
2024-11-18 21:06:18 +00:00
Alessio Bazzica
56085ea0d1 AGC2 test: add missing include
Bug: webrtc:42232605
Change-Id: I8fcb66cf8ee27bf630433cdfee4a3386138cd7a7
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/365521
Owners-Override: Jesus de Vicente Pena <devicentepena@webrtc.org>
Commit-Queue: Alessio Bazzica <alessiob@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Jesus de Vicente Pena <devicentepena@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43419}
2024-11-18 17:13:32 +00:00
Alessio Bazzica
331ca30635 Remove py_quality_assessment and old TODOs in conversational_speech
Bug: webrtc:379542219
Change-Id: I7a6c087ce42f854d9b440da018248323b2435b55
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/368500
Reviewed-by: Sam Zackrisson <saza@webrtc.org>
Commit-Queue: Alessio Bazzica <alessiob@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43418}
2024-11-18 15:13:06 +00:00
Dor Hen
69cc695699 Comment unused variables in implemented functions 14\n
Bug: webrtc:370878648
Change-Id: I7c48313e64fafb8f23121e9bae1d50c3d32f7d07
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/366983
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Commit-Queue: Dor Hen <dorhen@meta.com>
Cr-Commit-Position: refs/heads/main@{#43414}
2024-11-18 11:32:25 +00:00
Johannes Kron
bda11ca6da Add histogram WebRTC.Video.EstimatedClockDrift_ppm
TimestampExtrapolator maps RTP timestamps of received video frames
to local timestamps. As part of this mapping, the clock drift
between the local and remote clock is estimated.

Add the histogram WebRTC.Video.EstimatedClockDrift_ppm  to log the
relative clock drift in points per million.

Bug: b/363166487
Change-Id: I0c2e628ef72c05a93e1f3138c8f71c77467130b7
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/368342
Reviewed-by: Rasmus Brandt <brandtr@webrtc.org>
Commit-Queue: Johannes Kron <kron@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43413}
2024-11-18 10:47:30 +00:00
Qiu Jianlin
c79be57b47 Reland "Set default scalability mode for H.265 to L1T1."
This is a reland of commit 775639e930f14a619974944594b40c633cc574a3

Original change's description:
> Set default scalability mode for H.265 to L1T1.
>
> H.265 does not have software fallback, and it may have issue supporting
> more than 1 temporal layers on some devices. Set default to L1T1 when
> scalability is not configured, or if a scalability mode is reported as
> not supported by encoder.
>
> Bug: chromium:41480904
> Change-Id: I53895c45ec821d65774ffe2db5f418184e3fb02a
> Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/367835
> Reviewed-by: Sergey Silkin <ssilkin@webrtc.org>
> Reviewed-by: Ilya Nikolaevskiy <ilnik@webrtc.org>
> Commit-Queue: Jianlin Qiu <jianlin.qiu@intel.com>
> Cr-Commit-Position: refs/heads/main@{#43389}

Bug: chromium:41480904
Change-Id: Idedf6249130bd01dd31261672c624b88c3f4c1de
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/368261
Reviewed-by: Erik Språng <sprang@webrtc.org>
Reviewed-by: Ilya Nikolaevskiy <ilnik@webrtc.org>
Reviewed-by: Sergey Silkin <ssilkin@webrtc.org>
Commit-Queue: Jianlin Qiu <jianlin.qiu@intel.com>
Commit-Queue: Ilya Nikolaevskiy <ilnik@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43412}
2024-11-18 10:25:33 +00:00
Harald Alvestrand
0c6d31919e Enable RFC 8888 feedback if negotiated
This will turn on RFC 8888 feedback messages if "ack ccfb" is negotiated.

This should eliminate the need for the "force" flag in the field trial.

Bug: webrtc:42225697
Change-Id: Iec7a894c244a417a8499200861550a33f89966a2
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/367400
Reviewed-by: Per Kjellander <perkj@webrtc.org>
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43398}
2024-11-14 06:27:45 +00:00
Ilya Nikolaevskiy
54ed3ad524 Revert "Set default scalability mode for H.265 to L1T1."
This reverts commit 775639e930f14a619974944594b40c633cc574a3.

Reason for revert: Breaks internal tests.

Original change's description:
> Set default scalability mode for H.265 to L1T1.
>
> H.265 does not have software fallback, and it may have issue supporting
> more than 1 temporal layers on some devices. Set default to L1T1 when
> scalability is not configured, or if a scalability mode is reported as
> not supported by encoder.
>
> Bug: chromium:41480904
> Change-Id: I53895c45ec821d65774ffe2db5f418184e3fb02a
> Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/367835
> Reviewed-by: Sergey Silkin <ssilkin@webrtc.org>
> Reviewed-by: Ilya Nikolaevskiy <ilnik@webrtc.org>
> Commit-Queue: Jianlin Qiu <jianlin.qiu@intel.com>
> Cr-Commit-Position: refs/heads/main@{#43389}

Bug: chromium:41480904
No-Try: true
Change-Id: I5485b1abfd5f586ec187cc57817940aa2efd72af
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/368200
Bot-Commit: rubber-stamper@appspot.gserviceaccount.com <rubber-stamper@appspot.gserviceaccount.com>
Auto-Submit: Ilya Nikolaevskiy <ilnik@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Jeremy Leconte <jleconte@webrtc.org>
Owners-Override: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43396}
2024-11-13 16:02:03 +00:00
Alessio Bazzica
ebb11c4c87 With stereo decoding and mono packets produce mono after CN/PLC
The workaround in https://webrtc-review.googlesource.com/c/src/+/367740
is incomplete because it does not fix the issue for the first decoded
mono packet after CN/PLC. This CL extends the workaround to such a case
and adds a unit test for it.

Note: it was verified that the 2nd packet after CN/PLC is trivial
stereo.

Credits: jakobi@webrtc.org for raising the concern

Bug: webrtc:376493209
Change-Id: Ide27e411781693f14629cf9db8b6c0c0fc762a17
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/368160
Reviewed-by: Jakob Ivarsson‎ <jakobi@webrtc.org>
Commit-Queue: Alessio Bazzica <alessiob@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43393}
2024-11-13 14:47:29 +00:00
Shunbo Li
b7f5e7fb29 Fix video renderer slowdown by wrong RenderTime
This commit fixes the issue of video playback in slow motion caused by VCMTiming being unable to provide the correct rendering time in
 scenarios of continuous network packet loss

WANT_LGTM=mbonadei

Bug: webrtc:376183208
Change-Id: I63617068506e536c4b812215ea084eec18e8ee06
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/367000
Reviewed-by: Rasmus Brandt <brandtr@webrtc.org>
Reviewed-by: Ilya Nikolaevskiy <ilnik@webrtc.org>
Commit-Queue: Ilya Nikolaevskiy <ilnik@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43392}
2024-11-13 14:45:29 +00:00
Qiu Jianlin
775639e930 Set default scalability mode for H.265 to L1T1.
H.265 does not have software fallback, and it may have issue supporting
more than 1 temporal layers on some devices. Set default to L1T1 when
scalability is not configured, or if a scalability mode is reported as
not supported by encoder.

Bug: chromium:41480904
Change-Id: I53895c45ec821d65774ffe2db5f418184e3fb02a
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/367835
Reviewed-by: Sergey Silkin <ssilkin@webrtc.org>
Reviewed-by: Ilya Nikolaevskiy <ilnik@webrtc.org>
Commit-Queue: Jianlin Qiu <jianlin.qiu@intel.com>
Cr-Commit-Position: refs/heads/main@{#43389}
2024-11-12 11:50:52 +00:00
Jan Grulich
a5d71009ac PipeWire camera: use better unique device name for camera devices
Originally we used node id from PipeWire as an unique device name and
while this works, it will change everytime PipeWire is restarted. This
has an impact on default camera selection, where for example Firefox can
automatically request a camera device that was used before, but this can
break with the next PipeWire restart.

Bug: webrtc:42225999
Change-Id: I9440ee065ffeaa1ffb911a4dc7c405d57c9416dc
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/367880
Commit-Queue: Jan Grulich <grulja@gmail.com>
Reviewed-by: Ilya Nikolaevskiy <ilnik@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43387}
2024-11-11 19:01:34 +00:00
Danil Chapovalov
c772fc227b Deprecate AudioProcessingBuilder in favor of the BuiltinAudioProcessingBuilder
Update comments and doc mentioning AudioProcessingBuilder accordingly

Bug: webrtc:369904700
Change-Id: If837ddace5fedce94853c80500c6a832de8db9c7
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/367520
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Commit-Queue: Danil Chapovalov <danilchap@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43376}
2024-11-08 09:54:53 +00:00
Alessio Bazzica
c7824dba06 With stereo decoding and mono packets produce mono DTX/concealment
Adding a temporary workaround in the WebRTC Opus decoder wrapper to fix
https://issues.webrtc.org/376493209. Once the issue is fixed in libopus,
the workaround must be removed (TODO added in the code).

The workaround keeps track of the number of channels for the last
decoded packet and, if the decoder operates in stereo mode and the last
packet was a mono one, the left channel is copied into the right one
when comfort noise / PLC audio is generated.

Bug: webrtc:376493209
Change-Id: Iad3bfb1b393bd68833decf51b69b5238cb0ec4b7
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/367740
Commit-Queue: Alessio Bazzica <alessiob@webrtc.org>
Reviewed-by: Jakob Ivarsson‎ <jakobi@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43371}
2024-11-07 16:11:32 +00:00