aboutsummaryrefslogtreecommitdiff
path: root/pc
AgeCommit message (Collapse)Author
2024-03-26Update LegacyStatsCollector to conform with Wc++11-narrowingTommi
Cherry-picked from upstream: https://webrtc-review.googlesource.com/c/src/+/332240 Bug: 322868540 Change-Id: Ida6a1af5c324473a55ea4f3b143862ea016ff50a
2022-12-27Merge commit 'upstream-main' into masterJorge E. Moreira
Bug: 261600888 Test: none, build files to be updated in follow up cl Change-Id: Ib520938290c6bbdee4a9f73b6419b6c947a96ec4
2022-12-05sdp: parse a=msid:<stream_id> w/o msid-appdataPhilipp Hancke
parse a=msid:<stream_id> since JSEP stipulates sending this syntax as track identifers have become meaningless. The track id will be set to a random string. a=msid:<stream_id> <track_id> remains supported for backward compability. BUG=webrtc:14729 Change-Id: I86c073eb97cd613324271125de18a773235fc79d Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/285783 Reviewed-by: Harald Alvestrand <hta@webrtc.org> Reviewed-by: Florent Castelli <orphis@webrtc.org> Commit-Queue: Philipp Hancke <phancke@microsoft.com> Cr-Commit-Position: refs/heads/main@{#38814}
2022-12-01Delete deprecated disable_ipv6 flag.Henrik Boström
M108 Stable has been released, which does not contain googIPv6 anymore, and today the last downstream dependency on this flag was removed. Let's delete! Bug: webrtc:14608 Change-Id: Ia2d201f0da04b14961f891687b6135fc69b7767e Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/285720 Auto-Submit: Henrik Boström <hbos@webrtc.org> Reviewed-by: Harald Alvestrand <hta@webrtc.org> Commit-Queue: Henrik Boström <hbos@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38786}
2022-11-29Limit number of TURN servers to 32Philipp Hancke
Limit the number of TURN servers to 32 in order to allow the prioritization to assume a fixed offset for (de)prioritizing candidates. See https://github.com/w3c/webrtc-pc/pull/2679 for discussion including some data on current usage. Guarded by WebRTC-LimitTurnServers which is used as a killswitch. BUG=webrtc:13195 Change-Id: Ib12726af426ae4238aa7eb6aa062c71af52d495f Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/285340 Reviewed-by: Harald Alvestrand <hta@webrtc.org> Commit-Queue: Philipp Hancke <phancke@microsoft.com> Reviewed-by: Florent Castelli <orphis@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38767}
2022-11-29sdp: measure codec collisions in bundlePhilipp Hancke
as described in https://www.rfc-editor.org/rfc/rfc8843#name-payload-type-pt-value-reuse ... all codecs associated with the payload type number MUST share an identical codec configuration See also https://github.com/w3c/webrtc-stats/issues/664 Measure how much this would break in UMA first BUG=webrtc:14420,webrtc:12716 Change-Id: Iafdc70248aa22bc37c15cc88a0c244398cb58176 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/273881 Reviewed-by: Harald Alvestrand <hta@webrtc.org> Reviewed-by: Henrik Boström <hbos@webrtc.org> Commit-Queue: Philipp Hancke <phancke@microsoft.com> Cr-Commit-Position: refs/heads/main@{#38759}
2022-11-22Unvirtualize more wasteful functionsIvan Rosales
Cleaning up instances of virtual functions with no overrides. Savings of 1.4kb for chrome.dll file. Note: These are the savings for Windows, relocation savings are probably larger on other platforms. GN args for builds: use_goma=true is_debug=false target_cpu="x64" use_lld=false fatal_linker_warnings=false symbol_level=2 dcheck_always_on = false pe_summarize analysis pre-change -> change: Size of out\Default\chrome.dll is 188.844544 MB Size of out\SessionDescription\chrome.dll is 188.843520 MB Memory size change from out\Default\chrome.dll to out\SessionDescription\chrome.dll .text: -704 bytes change .rdata: -512 bytes change .pdata: -48 bytes change .reloc: -168 bytes change Total change: -1432 bytes Bug: chromium:1371503 Change-Id: I51ad0a8acf3595fc499dbbcde2fab2d1bdf90fb9 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/283940 Commit-Queue: Ivan Rosales <rosalesi@google.com> Reviewed-by: Henrik Boström <hbos@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38713}
2022-11-22[Stats] If remote-inbound-rtp has no RTT, leave it undefined.Henrik Boström
Bug: webrtc:14692 Change-Id: I49878449cd91b590f1aedef7676c3715d563ac61 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/284660 Commit-Queue: Henrik Boström <hbos@webrtc.org> Auto-Submit: Henrik Boström <hbos@webrtc.org> Reviewed-by: Harald Alvestrand <hta@webrtc.org> Commit-Queue: Harald Alvestrand <hta@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38706}
2022-11-18Reland "[DVQA] Create separate BUILD.gn file for video analyzer"Ilya Nikolaevskiy
This reverts commit 76793c300fdd87fa8fd8be3dd2e5faf8c1916e96. Reason for revert: Can't cleanly revert the old one. A forward fix will be provided. Original change's description: > Revert "[DVQA] Create separate BUILD.gn file for video analyzer" > > This reverts commit 116c0a53d4a35c6dee857eb4cc2b6ae233a0427c. > > Reason for revert: Breaks bot: https://ci.chromium.org/ui/p/chromium/builders/try/linux_chromium_compile_dbg_ng/1415352/overview > > > Original change's description: > > [DVQA] Create separate BUILD.gn file for video analyzer > > > > Bug: None > > Change-Id: I37dd2262bf3f52b2f5abe7934b9c41eaa27ffd17 > > No-try: True > > Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/283141 > > Commit-Queue: Artem Titov <titovartem@webrtc.org> > > Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org> > > Cr-Commit-Position: refs/heads/main@{#38662} > > Bug: None > Change-Id: Ieeb8c569560cb9d60d0c4d3c1268fa57f56b8157 > No-Presubmit: true > No-Tree-Checks: true > No-Try: true > Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/284000 > Auto-Submit: Ilya Nikolaevskiy <ilnik@webrtc.org> > Bot-Commit: rubber-stamper@appspot.gserviceaccount.com <rubber-stamper@appspot.gserviceaccount.com> > Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org> > Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org> > Cr-Commit-Position: refs/heads/main@{#38672} Bug: None Change-Id: I74506eaa6a1060bf87e651881c86b4f576f447ec Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/284020 Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org> 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> Cr-Commit-Position: refs/heads/main@{#38676}
2022-11-18Revert "[DVQA] Create separate BUILD.gn file for video analyzer"Ilya Nikolaevskiy
This reverts commit 116c0a53d4a35c6dee857eb4cc2b6ae233a0427c. Reason for revert: Breaks bot: https://ci.chromium.org/ui/p/chromium/builders/try/linux_chromium_compile_dbg_ng/1415352/overview Original change's description: > [DVQA] Create separate BUILD.gn file for video analyzer > > Bug: None > Change-Id: I37dd2262bf3f52b2f5abe7934b9c41eaa27ffd17 > No-try: True > Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/283141 > Commit-Queue: Artem Titov <titovartem@webrtc.org> > Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org> > Cr-Commit-Position: refs/heads/main@{#38662} Bug: None Change-Id: Ieeb8c569560cb9d60d0c4d3c1268fa57f56b8157 No-Presubmit: true No-Tree-Checks: true No-Try: true Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/284000 Auto-Submit: Ilya Nikolaevskiy <ilnik@webrtc.org> Bot-Commit: rubber-stamper@appspot.gserviceaccount.com <rubber-stamper@appspot.gserviceaccount.com> Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org> Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38672}
2022-11-17Reland "[ACM] iSAC audio codec removed"Alessio Bazzica
This is a reland of commit b46c4bf27ba5c417fcba7f200d80fa4634e7e1a1 Original change's description: > [ACM] iSAC audio codec removed > > Note: this CL has to leave behind one part of iSAC, which is its VAD > currently used by AGC1 in APM. The target visibility has been > restricted and the VAD will be removed together with AGC1 when the > time comes. > > Tested: see https://chromium-review.googlesource.com/c/chromium/src/+/4013319 > > Bug: webrtc:14450 > Change-Id: I69cc518b16280eae62a1f1977cdbfa24c08cf5f9 > Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/282421 > Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org> > Reviewed-by: Sam Zackrisson <saza@webrtc.org> > Reviewed-by: Henrik Boström <hbos@webrtc.org> > Commit-Queue: Alessio Bazzica <alessiob@webrtc.org> > Cr-Commit-Position: refs/heads/main@{#38652} Bug: webrtc:14450 Change-Id: Ia22c4d7724b6022238235fede93e36e570a49376 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/283843 Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org> Commit-Queue: Alessio Bazzica <alessiob@webrtc.org> Reviewed-by: Sam Zackrisson <saza@webrtc.org> Reviewed-by: Henrik Boström <hbos@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38665}
2022-11-17[DVQA] Create separate BUILD.gn file for video analyzerArtem Titov
Bug: None Change-Id: I37dd2262bf3f52b2f5abe7934b9c41eaa27ffd17 No-try: True Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/283141 Commit-Queue: Artem Titov <titovartem@webrtc.org> Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38662}
2022-11-16Revert "[ACM] iSAC audio codec removed"Alessio Bazzica
This reverts commit b46c4bf27ba5c417fcba7f200d80fa4634e7e1a1. Reason for revert: breaks a downstream project Original change's description: > [ACM] iSAC audio codec removed > > Note: this CL has to leave behind one part of iSAC, which is its VAD > currently used by AGC1 in APM. The target visibility has been > restricted and the VAD will be removed together with AGC1 when the > time comes. > > Tested: see https://chromium-review.googlesource.com/c/chromium/src/+/4013319 > > Bug: webrtc:14450 > Change-Id: I69cc518b16280eae62a1f1977cdbfa24c08cf5f9 > Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/282421 > Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org> > Reviewed-by: Sam Zackrisson <saza@webrtc.org> > Reviewed-by: Henrik Boström <hbos@webrtc.org> > Commit-Queue: Alessio Bazzica <alessiob@webrtc.org> > Cr-Commit-Position: refs/heads/main@{#38652} Bug: webrtc:14450 Change-Id: Ice138004e84e8c5f896684e8d01133d4b2a77bb7 No-Presubmit: true No-Tree-Checks: true No-Try: true Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/283800 Reviewed-by: Alessio Bazzica <alessiob@webrtc.org> Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org> Auto-Submit: Alessio Bazzica <alessiob@webrtc.org> Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org> Owners-Override: Mirko Bonadei <mbonadei@webrtc.org> Bot-Commit: rubber-stamper@appspot.gserviceaccount.com <rubber-stamper@appspot.gserviceaccount.com> Cr-Commit-Position: refs/heads/main@{#38655}
2022-11-16[ACM] iSAC audio codec removedAlessio Bazzica
Note: this CL has to leave behind one part of iSAC, which is its VAD currently used by AGC1 in APM. The target visibility has been restricted and the VAD will be removed together with AGC1 when the time comes. Tested: see https://chromium-review.googlesource.com/c/chromium/src/+/4013319 Bug: webrtc:14450 Change-Id: I69cc518b16280eae62a1f1977cdbfa24c08cf5f9 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/282421 Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org> Reviewed-by: Sam Zackrisson <saza@webrtc.org> Reviewed-by: Henrik Boström <hbos@webrtc.org> Commit-Queue: Alessio Bazzica <alessiob@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38652}
2022-11-16Allow maxptime equal to minptime in the SDP.Shaofan Qi
The DCHECK crashes debug builds running some applications such as Webex. Bug: None Change-Id: I0061286c4c1d04964678a00014896f1fccd4685d Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/276460 Commit-Queue: Tomas Gunnarsson <tommi@webrtc.org> Reviewed-by: Tomas Gunnarsson <tommi@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38644}
2022-11-16Refactor some config plumbing in call/.Henrik Boström
Address perkj's comments left in https://webrtc-review.googlesource.com/c/src/+/283420. I was a bit trigger-happy with the submit button. Bug: chromium:1354491 Change-Id: Ifd052f75af3763b0b52807c31ea790e3efee921d Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/283521 Reviewed-by: Erik Språng <sprang@webrtc.org> Auto-Submit: Henrik Boström <hbos@webrtc.org> Commit-Queue: Erik Språng <sprang@webrtc.org> Reviewed-by: Per Kjellander <perkj@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38638}
2022-11-15Remove virtual from wasteful functionsIvan Rosales
I've been working with SizeBench (binary size analysis tool) and it reported that 39 virtual functions were not overridden. Removed virtual keyword from each. SizeBench estimated waste 2.1kb. Change made chrome.dll 5.3kb smaller. Since these 39 virtual functions are never overridden, they are wasteful. Note: These are the savings for Windows, relocation savings are probably larger on other platforms. GN args for builds: use_goma=true is_debug=false target_cpu="x64" use_lld=false fatal_linker_warnings=false symbol_level=2 dcheck_always_on = false pe_summarize analysis pre-change -> change: Size of out\Default\chrome.dll is 187.205120 MB Size of out\MediaContentDescription\chrome.dll is 187.199488 MB Memory size change from out\Default\chrome.dll to out\MediaContentDescription\chrome.dll .text: -2624 bytes change .rdata: -1984 bytes change .pdata: -48 bytes change .reloc: -644 bytes change Total change: -5300 bytes Bug: chromium:1371503 Change-Id: Ib33829fada54abdf8fed33ec96f11a03ce6fcb68 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/281442 Reviewed-by: Henrik Boström <hbos@webrtc.org> Commit-Queue: Ivan Rosales <rosalesi@google.com> Cr-Commit-Position: refs/heads/main@{#38630}
2022-11-15pc: Add asynchronous RtpSender::SetParameters() callFlorent Castelli
As the synchronous version only posts a task to recreate the encoder later, it is not possible to catch errors and state changes that could appear then. The asynchronous version of SetParameters() aims to solve this by providing a callback to wait for the completion of the encoder reconfiguration, allowing any error to be propagate and subsequent getParameters() call to have up to date information. Bug: webrtc:11607 Change-Id: I5548e75aa14a97f8d9c0c94df1e72e9cd40887b2 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/278420 Reviewed-by: Harald Alvestrand <hta@webrtc.org> Commit-Queue: Florent Castelli <orphis@webrtc.org> Reviewed-by: Erik Språng <sprang@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38627}
2022-11-15Add parameter to control the pacer's burst outside of field trials.Henrik Boström
BurstyPacer is currently controlled via field trials. In order for Chrome to be able to have burst without relying on a field trial, this parameter is added. When all burst experiments have concluded we may be able to have a hardcoded constant instead, but for now the parameter is added to RTCConfiguration. NOTRY=True Bug: chromium:1354491 Change-Id: I386c1651dbbcbf309c15ea3d3380cf8f632b5429 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/283420 Reviewed-by: Erik Språng <sprang@webrtc.org> Commit-Queue: Henrik Boström <hbos@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38621}
2022-11-14Delete api/stats_types.h in favor of api/legacy_stats_types.hHenrik Boström
The file was renamed, see https://groups.google.com/u/1/g/discuss-webrtc/c/ZQiP4f_bpw4 Bug: webrtc:14180 Change-Id: Ia76c85ba7d9da6b3a93d0a67a4b6a5187e07e230 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/283084 Commit-Queue: Harald Alvestrand <hta@webrtc.org> Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org> Auto-Submit: Henrik Boström <hbos@webrtc.org> Reviewed-by: Harald Alvestrand <hta@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38616}
2022-11-11Rename api/stats_types.h to api/legacy_stats_types.h.Henrik Boström
As to not break downstream projects, the old name api/stats_types.h is kept around to help include api/legacy_stats_types.h. We can delete this in a follow-up. NOTRY=True Bug: webrtc:14180 Change-Id: I270ca5e366ae36e324cbc9f982bbb066ab92d203 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/283081 Commit-Queue: Henrik Boström <hbos@webrtc.org> Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org> Reviewed-by: Harald Alvestrand <hta@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38610}
2022-11-10Add a new PeerConnectionE2EQualityTestFixture::AddPeer method.Jeremy Leconte
Change-Id: Ic5879613db51a00e3e958931f5eda19fda1ae94a Bug: webrtc:14627 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/282640 Reviewed-by: Artem Titov <titovartem@webrtc.org> Commit-Queue: Jeremy Leconte <jleconte@google.com> Reviewed-by: Harald Alvestrand <hta@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38608}
2022-11-10Metronome: complete API migration.Markus Handell
This CL finalizes the Metronome refactor undertaken in crbug.com/1381982 and enables it again in call.cc. Fixed: chromium:1381982 Change-Id: I1642103e9c8a3f2a1f12d7635a1b27310802c1c3 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/282920 Commit-Queue: Markus Handell <handellm@webrtc.org> Reviewed-by: Evan Shrubsole <eshr@webrtc.org> Reviewed-by: Erik Språng <sprang@webrtc.org> Reviewed-by: Per Kjellander <perkj@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38605}
2022-11-09generateKeyFrame: validate rids argumentPhilipp Hancke
BUG=chromium:1354101 Change-Id: Ie850d807e47c72470a50daffec5679c7a23111dc Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/282380 Reviewed-by: Florent Castelli <orphis@webrtc.org> Commit-Queue: Philipp Hancke <phancke@microsoft.com> Reviewed-by: Ilya Nikolaevskiy <ilnik@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38591}
2022-11-08Metronome: disable & refactor for single-threaded operation.Markus Handell
The Chromium implementation unfortunately has a rare deadlock. Rather than patching that up, we're changing the metronome implementation to be able to use a single-threaded environment instead. The metronome functionality is disabled in VideoReceiveStream2 construction inside call.cc. The new design does not have listener registration or deresigstration and instead accepts and invokes callbacks, on the same sequence that requested the callback. This allows the clients to use features such as WeakPtrFactories or ScopedThreadSafety for cancellation. The CL will be followed up with cleanup CLs that removes registration APIs once downstream consumers have adapted. Bug: chromium:1381982 Change-Id: I43732d1971e2276c39b431a04365cd2fc3c55c25 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/282280 Reviewed-by: Per Kjellander <perkj@webrtc.org> Reviewed-by: Erik Språng <sprang@webrtc.org> Reviewed-by: Evan Shrubsole <eshr@webrtc.org> Commit-Queue: Markus Handell <handellm@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38582}
2022-11-08Delete ChannelManager class declaration.Yaowen Guo
ChannelManager has been deleted, these declaration should also be deleted. Bug: webrtc:13931 Change-Id: I2739a0424f61d6e659cb694a3f51bb6b90911cf9 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/282520 Commit-Queue: Tomas Gunnarsson <tommi@webrtc.org> Reviewed-by: Tomas Gunnarsson <tommi@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38579}
2022-11-08Add power efficient stats to RTC statsEvan Shrubsole
As the exposure of power efficient stats to JavaScript are limited as to reduce the fingerprinting surface to getStats, a new RTCStatsMember derivation, RTCLimitedStatsMember, was added in this change. This sets the exposure criteria of the stat on the type, which keeps the size of the RTCStatsMember class the same and allows for extension in the future for new types of stat restrictions. Bug: webrtc:14483 Change-Id: Ib0303050a112441ba2416fd5f004dd8be26b47ca Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/279021 Commit-Queue: Evan Shrubsole <eshr@webrtc.org> Reviewed-by: Henrik Boström <hbos@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38576}
2022-11-07generateKeyFrame: add rids argumentPhilipp Hancke
and do the resolution of rids to layers. This has no effect yet since the simulcast encoder adapter (SimulcastEncoderAdapter::Encode), the VP8 encoder (LibvpxVp8Encoder::Encode) and the OpenH264 encoder (H264EncoderImpl::Encode) all generate a key frame for all layers whenever a key frame is requested on one layer. BUG=chromium:1354101 Change-Id: I13f5f1bf136839a68942b0f6bf4f2d5890415250 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/280945 Commit-Queue: Ilya Nikolaevskiy <ilnik@webrtc.org> Commit-Queue: Philipp Hancke <phancke@microsoft.com> Reviewed-by: Ilya Nikolaevskiy <ilnik@webrtc.org> Reviewed-by: Harald Alvestrand <hta@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38565}
2022-11-03stats: more consistent use of has_value() for optionalsPhilipp Hancke
replacing if (optional) { ...} with the more explicit if (optional.has_value()) { ... } No functional changes. BUG=None Change-Id: I005fd3df307880b07cfda0cbe435efb0e0717a88 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/281362 Reviewed-by: Henrik Boström <hbos@webrtc.org> Reviewed-by: Harald Alvestrand <hta@webrtc.org> Commit-Queue: Philipp Hancke <phancke@microsoft.com> Cr-Commit-Position: refs/heads/main@{#38544}
2022-11-03Reland "move relay server priority assignment to port_allocator"Jonas Oreland
This is a reland of commit b395f5bd5c5be7a3b54fc85ca482759a56a0cd6e Downstream project has been fixed. Original change's description: > move relay server priority assignment to port_allocator > > which knows more about the internals of ICE. > Remove the relay server config priority field which was used to > specify the relative priority of TURN servers. This is now handled > internally by CreateRelayPortArgs without being exposed. > > Also rename BasicPortAllocator::AddTurnServer to > BasicPortAllocator::AddTurnServerForTesting since it is a test-only > method. > > BUG=webrtc:13195,webrtc:14539 > > Change-Id: Id36cbf0187b7a84d1a9b53860f31994f3c7589f0 > Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/280224 > Commit-Queue: Philipp Hancke <phancke@microsoft.com> > Reviewed-by: Harald Alvestrand <hta@webrtc.org> > Reviewed-by: Jonas Oreland <jonaso@webrtc.org> > Cr-Commit-Position: refs/heads/main@{#38520} Bug: webrtc:13195,webrtc:14539 Change-Id: I617b611de97e4013c7286e3345073ca7589065c5 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/281662 Commit-Queue: Jonas Oreland <jonaso@webrtc.org> Reviewed-by: Philipp Hancke <phancke@microsoft.com> Reviewed-by: Harald Alvestrand <hta@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38543}
2022-11-03transport controller: move ice transport initializationPhilipp Hancke
out of the DTLS transport creation and into the ICE transport creation. BUG=None Change-Id: I9f1a74bbabde842234e5ae7cc64aa9632ab2ba78 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/281480 Reviewed-by: Harald Alvestrand <hta@webrtc.org> Reviewed-by: Florent Castelli <orphis@webrtc.org> Commit-Queue: Philipp Hancke <phancke@microsoft.com> Cr-Commit-Position: refs/heads/main@{#38541}
2022-11-02stats: implement candidate-pair lastPacket(Sent|Received)TimestampPhilipp Hancke
https://w3c.github.io/webrtc-stats/#dom-rtcicecandidatepairstats-lastpacketsenttimestamp https://w3c.github.io/webrtc-stats/#dom-rtcicecandidatepairstats-lastpacketreceivedtimestamp which are useful together with the ice-restart-necessary logic mentioned in https://w3c.github.io/webrtc-pc/#dictionary-rtcofferoptions-members BUG=webrtc:14619 Change-Id: I4a8ab00a37fbd4af8b948720c83787cbdfc6b9a3 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/281281 Reviewed-by: Henrik Boström <hbos@webrtc.org> Reviewed-by: Harald Alvestrand <hta@webrtc.org> Commit-Queue: Philipp Hancke <phancke@microsoft.com> Cr-Commit-Position: refs/heads/main@{#38534}
2022-11-02[Stats] Delete 'track' metrics that have previously been moved.Henrik Boström
These have all been moved to "inbound-rtp" and now that upstream projects have migrated we can delete the old location. Unblocks https://crbug.com/webrtc/14175 Bug: webrtc:14521, webrtc:14524 Change-Id: Ia2bfa399d62304cc0ead0e65c340dfad20acc530 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/281183 Reviewed-by: Harald Alvestrand <hta@webrtc.org> Auto-Submit: Henrik Boström <hbos@webrtc.org> Commit-Queue: Harald Alvestrand <hta@webrtc.org> Commit-Queue: Henrik Boström <hbos@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38532}
2022-11-01Revert "move relay server priority assignment to port_allocator"Artem Titov
This reverts commit b395f5bd5c5be7a3b54fc85ca482759a56a0cd6e. Reason for revert: Breaks downstream project. Jonas will help to reland this CL. Original change's description: > move relay server priority assignment to port_allocator > > which knows more about the internals of ICE. > Remove the relay server config priority field which was used to > specify the relative priority of TURN servers. This is now handled > internally by CreateRelayPortArgs without being exposed. > > Also rename BasicPortAllocator::AddTurnServer to > BasicPortAllocator::AddTurnServerForTesting since it is a test-only > method. > > BUG=webrtc:13195,webrtc:14539 > > Change-Id: Id36cbf0187b7a84d1a9b53860f31994f3c7589f0 > Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/280224 > Commit-Queue: Philipp Hancke <phancke@microsoft.com> > Reviewed-by: Harald Alvestrand <hta@webrtc.org> > Reviewed-by: Jonas Oreland <jonaso@webrtc.org> > Cr-Commit-Position: refs/heads/main@{#38520} Bug: webrtc:13195,webrtc:14539 Change-Id: I7ca087a272793908f003cea6c32efe6214e54028 No-Presubmit: true No-Tree-Checks: true No-Try: true Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/281340 Owners-Override: Artem Titov <titovartem@webrtc.org> Commit-Queue: Artem Titov <titovartem@webrtc.org> Bot-Commit: rubber-stamper@appspot.gserviceaccount.com <rubber-stamper@appspot.gserviceaccount.com> Cr-Commit-Position: refs/heads/main@{#38524}
2022-11-01move relay server priority assignment to port_allocatorPhilipp Hancke
which knows more about the internals of ICE. Remove the relay server config priority field which was used to specify the relative priority of TURN servers. This is now handled internally by CreateRelayPortArgs without being exposed. Also rename BasicPortAllocator::AddTurnServer to BasicPortAllocator::AddTurnServerForTesting since it is a test-only method. BUG=webrtc:13195,webrtc:14539 Change-Id: Id36cbf0187b7a84d1a9b53860f31994f3c7589f0 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/280224 Commit-Queue: Philipp Hancke <phancke@microsoft.com> Reviewed-by: Harald Alvestrand <hta@webrtc.org> Reviewed-by: Jonas Oreland <jonaso@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38520}
2022-11-01ice: include tiebreaker in computation of foundation attribute (tests)Philipp Hancke
split from the actual change for easier review and cherry-picking. BUG=webrtc:14605 Change-Id: I7dbaf8e1f4a03f35a5d8c4da1a2784b00589bfc3 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/280680 Commit-Queue: Philipp Hancke <phancke@microsoft.com> Reviewed-by: Jonas Oreland <jonaso@webrtc.org> Reviewed-by: Harald Alvestrand <hta@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38519}
2022-10-31Unship track.totalFramesDuration/sumSquaredFrameDurations.Henrik Boström
These metrics were not only non-standard, but residing in the non-standard "track" stats object that we want to delete. As per https://github.com/w3c/webrtc-stats/issues/695#issuecomment-1259611462 these metrics are no longer needed because we already have inbound-rtp.totalInterFrameDelay/totalSquaredInterFrameDelay which is basically the same thing. // mac_rel infra failures are unrelated NOTRY=True Bug: webrtc:14522 Change-Id: I565da42514a93f15532ba8357dd006547a5296ee Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/278100 Commit-Queue: Henrik Boström <hbos@webrtc.org> Reviewed-by: Harald Alvestrand <hta@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38509}
2022-10-30Make disable_ipv6 ABSL_DEPRECATED.Henrik Boström
// All tests pass, infra failure unrelated NOTRY=True Bug: webrtc:14608 Change-Id: Ie16dcf9dc66e687f0befef42c7d8e914696af191 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/280760 Reviewed-by: Harald Alvestrand <hta@webrtc.org> Commit-Queue: Henrik Boström <hbos@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38502}
2022-10-27ice: include tiebreaker in computation of foundation attributePhilipp Hancke
the foundation attribute is currently calculated as CRC32(baseaddress, protocol, relayprotocol) which is a way to satisfy the requirements from https://www.rfc-editor.org/rfc/rfc5245#section-4.1.1.3 However, this leaks the base address which defeats the MDNS obfuscation described in https://datatracker.ietf.org/doc/draft-ietf-mmusic-mdns-ice-candidates/ since the CRC32 can be reversed using a table lookup as shown in https://github.com/niespodd/webrtc-local-ip-leak/ To defeat that lookup, "seed" the CRC32 with the ICE tie-breaker which is a randomly picked unsigned 64 bit integer described in https://www.rfc-editor.org/rfc/rfc5245#section-5.2 The tie-breaker is not known to Javascript and adding it scopes the foundation within the peer connection as described in section 4.1.1.3 To manually test (preferably with a DCHECK for IceTiebreaker() in ComputeFoundation) - gather candidates twice on https://webrtc.github.io/samples/src/content/peerconnection/trickle-ice/ and observe that the foundations are not the same after this change - create two RTCPeerConnections with {iceCandidatePoolSize: 1}, create a datachannel, call setLocalDescription, inspect the candidates and observe that the foundations are not the same after this change. Unit test changes have been split into a separate CL for easier integration. BUG=webrtc:14605 Change-Id: I6bbad1635b48997b00ae74d251ae357bf8afd12f Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/280621 Reviewed-by: Harald Alvestrand <hta@webrtc.org> Reviewed-by: Jonas Oreland <jonaso@webrtc.org> Commit-Queue: Harald Alvestrand <hta@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38485}
2022-10-27[Stats] Expose totalPacketSendDelay for audio as well.Henrik Boström
This information is now readily available. Let's expose it. In practise we don't pace audio by default and the delay is ~0, however we can tell that this metric is working as intended by setting PacingController's pace_audio_ to true via the "WebRTC-Pacer-BlockAudio" field trial. In this case chrome://webrtc-internals/ plots neats graphs for audio send delay. Bug: webrtc:10635 Change-Id: Iecfd93bb84ec61e5d54232769a9e7a500601b199 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/280523 Reviewed-by: Harald Alvestrand <hta@webrtc.org> Reviewed-by: Erik Språng <sprang@webrtc.org> Commit-Queue: Henrik Boström <hbos@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38483}
2022-10-26[Stats] Update totalPacketSendDelay to only cover time in pacer queue.Henrik Boström
This metric was always supposed to be the spec's answer to googBucketDelay, and is defined as "The total number of seconds that packets have spent buffered locally before being transmitted onto the network." But our implementation measured the time between capture and send, including encode time. This is incorrect and yields a much larger value than expected. This CL updated the metric to do what the spec says. Implementation-wise we measure the time between pushing and popping each packet from the queue (in modules/pacing/prioritized_packet_queue.cc). The spec says to increment the delay counter at the same time as we increment the packet counter in order for the app to be able to do "delta totalPacketSendDelay / delta packetSent". For this reason, `total_packet_delay` is added to RtpPacketCounter. (Previously, the two counters were incremented on different threads and observers.) Running Google Meet on a good network, I could observe a 2-3 ms average send delay per packet with this implementation compared to 20-30 ms with the old implementation. See b/137014977#comment170 for comparison with googBucketDelay which is a little bit different by design - totalPacketSendDelay is clearly better than googBucketDelay. Since none of this depend on the media kind, we can wire up this metric for audio as well in a follow-up: https://webrtc-review.googlesource.com/c/src/+/280523 Bug: webrtc:14593 Change-Id: If8fcd82fee74030d0923ee5df2c2aea2264600d4 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/280443 Reviewed-by: Erik Språng <sprang@webrtc.org> Commit-Queue: Henrik Boström <hbos@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38480}
2022-10-25add RTCRtpSender.generateKeyFramePhilipp Hancke
defined in https://w3c.github.io/webrtc-encoded-transform/#rtcrtpsender-extension Note: this does not implement the "rid(s)" parameter which will be done in a future CL. VP8 still synchronizes keyframes on all layers even when asked for ones on individual layers while H264 (when implemented as three different encoders in SimulcastEncoderAdapter) can actually utilize this. This does not change the behavior when receiving a RTCP PLI for a particular layer. BUG=chromium:1354101 Change-Id: Ic8b14d155242e32c9aeafa55fe6652f346ac76b8 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/274169 Reviewed-by: Harald Alvestrand <hta@webrtc.org> Reviewed-by: Ilya Nikolaevskiy <ilnik@webrtc.org> Commit-Queue: Philipp Hancke <phancke@microsoft.com> Cr-Commit-Position: refs/heads/main@{#38472}
2022-10-19[Stats] Add googTimingFrameInfo to the modern API.Henrik Boström
This is exposing something that is already exposed in the legacy getStats() API and is only available if the "video-timing" header extension is used. Adding this metric here should unblock legacy getStats() API deprecation. The follow-up to unship or standardize this metric is tracked by https://crbug.com/webrtc/14586. Bug: webrtc:14587 Change-Id: Ic3d45b0558d7caf4be2856a4cd95b88db312f85e Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/279860 Reviewed-by: Harald Alvestrand <hta@webrtc.org> Commit-Queue: Henrik Boström <hbos@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38444}
2022-10-19Add ability to set bitrate of DegradedCall via PeerConnection::SetBitrateByoungchan Lee
Bug: None Change-Id: Iac8970c95a01c1322fa65a19ab11ffd8f94412e0 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/279200 Commit-Queue: Daniel.L (Byoungchan) Lee <daniel.l@hpcnt.com> Reviewed-by: Tomas Gunnarsson <tommi@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38442}
2022-10-19[ModernStats] Mark obsolete stats as [[deprecated]].Henrik Boström
This includes the stats dictionaries that have been made obsolete in the spec and whose IDs are prefixed "DEPRECATED_": - RTCMediaStreamTrackStats - RTCMediaStreamStats There is an ongoing experiment to unship these stats dictionaries in Chrome (https://crbug.com/1374215). Marking then as [[deprecated]] helps alert other dependencies that these classes are deprecated. In the meantime, the "DEPRECATED_RTCMediaStreamTrackStats" prefix makes it possible to use the deprecated classes. # Unrelated infra failures NOTRY=True Bug: webrtc:14175, webrtc:14419 Change-Id: I498d370294058a628278e1e5b027cd12e24ad31a Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/279700 Reviewed-by: Harald Alvestrand <hta@webrtc.org> Commit-Queue: Henrik Boström <hbos@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38439}
2022-10-19Add optional init_send_encodings to AddTrackJonas Oreland
This patch adds variant of PeerConnectionInterface::AddTrack that takes an initial_send_encodings. This allows for setting/modifying encoding parameters before sdp negotiation is performed/complete (e.g requested_resolution). This is already available if using RtpTransciverInit and AddTransceiver, but was not added to AddTrack because of concerns that it complicated matching with existing transceivers. This CL sidesteps that by never matching to a preexisting transceiver if initial_send_encodings are specified. Note: 1) The patch adds a new method rather than an extra (e.g optional) argument to existing AddTrack. This is to avoid problems with downstream mocks. 2) chromium "problems" was fixed in https://chromium-review.googlesource.com/c/chromium/src/+/3952684 and https://chromium-review.googlesource.com/c/chromium/src/+/3956060 Bug: webrtc:14451 Change-Id: I19b5a03872730280fbf868ca5d3a2f46443359f3 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/278783 Reviewed-by: Harald Alvestrand <hta@webrtc.org> Commit-Queue: Jonas Oreland <jonaso@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38437}
2022-10-19Remove fields from remote candidates that could cause crashes in GetStatsByoungchan Lee
Typically, remote candidates come from signalling and are deserialized into C++ objects. The network_type field of these candidates is always ADAPTER_TYPE_UNKNOWN. However, in tests it is common to pass SDP and remote candidates as C++ objects. In this case, the network_type property of remote candidates is preserved, so DCHECK might be triggered when GetStats is called. Clearing fields that are not suitable as remote candidates fixes this issue. Bug: None Change-Id: Ida01b0224bce5cf3e87bcad1ddaca35c9f4fffe7 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/279680 Reviewed-by: Henrik Boström <hbos@webrtc.org> Commit-Queue: Henrik Boström <hbos@webrtc.org> Auto-Submit: Daniel.L (Byoungchan) Lee <daniel.l@hpcnt.com> Reviewed-by: Harald Alvestrand <hta@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38436}
2022-10-18SVC: Check scalability in AddTransceiver and SetParametersFlorent Castelli
ScalabilityMode should be validated against the currently allowed codecs or the currently used codec. Bug: webrtc:11607 Change-Id: Id2e6cbfad4f089de450150e1203657ed316e2f29 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/277403 Commit-Queue: Florent Castelli <orphis@webrtc.org> Reviewed-by: Harald Alvestrand <hta@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38433}
2022-10-14metrics: cleanup CandidatePoolUsage metricsPhilipp Hancke
which have shown that it is not easily possible to restrict the pool size to 1 and combine this with max-bundle BUG=webrtc:12383,chromium:1328218 Change-Id: I3a7ae4a263238c1b5faa079c3cbdaf84d1b40cbc Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/279141 Reviewed-by: Harald Alvestrand <hta@webrtc.org> Reviewed-by: Johannes Kron <kron@webrtc.org> Commit-Queue: Philipp Hancke <phancke@microsoft.com> Cr-Commit-Position: refs/heads/main@{#38396}
2022-10-13Reland "stats: migrate to Timestamp"Philipp Hancke
This is a reland of commit 2235776597e2f47ec353ac911428eb9a54d64a10 Original change's description: > stats: migrate to Timestamp > > BUG=webrtc:13756 > > Change-Id: I04ba57f9c2ca5a974a406814023911b4eb2d6d38 > Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/273942 > Commit-Queue: Philipp Hancke <phancke@microsoft.com> > Reviewed-by: Henrik Boström <hbos@webrtc.org> > Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org> > Cr-Commit-Position: refs/heads/main@{#38365} Bug: webrtc:13756 Change-Id: Ib8dc208197ae5e90f67114e7b043a73ee35421ea Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/279080 Reviewed-by: Henrik Boström <hbos@webrtc.org> Commit-Queue: Philipp Hancke <phancke@microsoft.com> Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org> Cr-Commit-Position: refs/heads/main@{#38380}