Commit graph

71 commits

Author SHA1 Message Date
Jim Gustafson
72d638d9de m130 merge fixes 2024-10-23 20:01:09 -07:00
Miriam Zimmerman
b25957f459
ringrtc: Clean up externally-specified keys code 2024-06-21 17:26:58 -04:00
Miriam Zimmerman
2cf10f1072 ringrtc: Propagate externally-negotiated keys. 2024-06-05 18:16:19 -04:00
Harald Alvestrand
e0b555e38d Remove code for supporting SDES
Rework transport_description_factory to only have non-DTLS mode for
testing, and rewrite tests accordingly.

Bug: webrtc:11066, chromium:804275
Change-Id: Ie7d477c4331c975e4e0a3034fbbb749ed9009446
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/336880
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Reviewed-by: Henrik Boström <hbos@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#41697}
2024-06-05 18:16:19 -04:00
Philipp Hancke
80a8683e30 sdp: tweak msid signaling further
* changing the defaults to unified-plan,
* expect unified-plan by default
* only include the msid-semantic line in answers when the
offer contained a sign of msid being used

BUG=webrtc:10421

Change-Id: I79364c2dd801d37adea119375e4dc01edf55b3be
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/331800
Reviewed-by: Henrik Boström <hbos@webrtc.org>
Commit-Queue: Philipp Hancke <phancke@microsoft.com>
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#41480}
2024-01-08 14:03:19 +00:00
Philipp Hancke
6f0f158af0 sdp: make msid support parsing more robust
by also taking into account any a=msid: line in addition to
msid-semantic. Also document issues with msid-semantic generation and unify support determination by removing the msid_supported flag.

BUG=webrtc:10421

Change-Id: Icea554ebd1998f2b526846457029eff6854a772a
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/329760
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Commit-Queue: Philipp Hancke <phancke@microsoft.com>
Reviewed-by: Henrik Boström <hbos@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#41386}
2023-12-14 14:50:31 +00:00
Philipp Hancke
971f8de35a Remove MediaContentDescriptionImpl<Codec>
after dependencies adopted the RtpMediaContentDescription which
this is currently aliased to.

Also move definition of AudioCodecs and VideoCodecs to the place
where codecs are defined.

BUG=webrtc:15214

Change-Id: I9b0456e1c69c8b23e0cc7665a59baae268872d9c
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/325021
Reviewed-by: Henrik Boström <hbos@webrtc.org>
Commit-Queue: Philipp Hancke <phancke@microsoft.com>
Reviewed-by: Florent Castelli <orphis@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#41020}
2023-10-27 12:38:36 +00:00
Philipp Hancke
19fe2437b7 Remove more codec-related templating
BUG=webrtc:15214

Change-Id: Ia597f674e5650dad31796c9a13769fbe873554fe
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/322122
Reviewed-by: Florent Castelli <orphis@webrtc.org>
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Commit-Queue: Philipp Hancke <phancke@microsoft.com>
Reviewed-by: Henrik Boström <hbos@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#40920}
2023-10-12 15:36:42 +00:00
Philipp Hancke
f14dfed72a Move codecs() to MediaContentDescription
allowing for a lot of de-templating

BUG=webrtc:15214

Change-Id: Ibe1a5f5d704564566f24c496822a4308ba23c4dd
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/319160
Commit-Queue: Philipp Hancke <phancke@microsoft.com>
Reviewed-by: Florent Castelli <orphis@webrtc.org>
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#40774}
2023-09-20 10:16:36 +00:00
Philipp Hancke
8c9e035edb Move codecs() to base MediaDescription
remove some of the templating around the Codec-derived types and
use more modern C++ loops.

BUG=webrtc:15214

Change-Id: I2710628741deca647e7ae88f5966ec7c7f12669a
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/311260
Commit-Queue: Philipp Hancke <phancke@microsoft.com>
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Reviewed-by: Florent Castelli <orphis@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#40475}
2023-07-26 05:37:51 +00:00
Ivan Rosales
447b9f3fde Unvirtualize more wasteful functions
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 22:44:21 +00:00
Ivan Rosales
2803ca27fb Remove virtual from wasteful functions
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-15 19:46:52 +00:00
Philipp Hancke
856eb25183 remove unused SetCnameIfEmpty
BUG=None

Change-Id: I3a2012b7d763efbbf79a6c39afc016b81d2d9af2
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/265385
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Commit-Queue: Philipp Hancke <philipp.hancke@googlemail.com>
Cr-Commit-Position: refs/heads/main@{#37175}
2022-06-10 08:58:44 +00:00
Niels Möller
f1d822b03b Delete variant of rtc::split that copies the output fields
Bug: webrtc:13579
Change-Id: I065a32704d48d5eed21aee0e9757cac9ecf7aa99
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/261951
Reviewed-by: Alessio Bazzica <alessiob@webrtc.org>
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Reviewed-by: Ali Tofigh <alito@webrtc.org>
Commit-Queue: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#37160}
2022-06-09 08:29:33 +00:00
Harald Alvestrand
c24a2189d7 Update IWYU tool with a mapping file
Also apply IWYU to all .cc files in pc/, and correct BUILD file to match.
Note: Some files came out wrong when iwyu was applied. These are not included.

Bug: none
Change-Id: Ib5ea46b8fcc505414d0447cca7218ad3afc2e321
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/252280
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#36064}
2022-02-24 11:05:06 +00:00
Harald Alvestrand
0d018415d5 Revert "Remove code supporting the SDES crypto mode in SDP"
This reverts commit ee212a72f2.

Reason for revert: Don't remove until downstream issues resolved

Original change's description:
> Remove code supporting the SDES crypto mode in SDP
>
> Removes the ability to accept nonencrypted answers to encrypted offers.
> Fixes some logic around bundled sessions and requirement for
> transport parameters.
>
> Bug: webrtc:11066
> Change-Id: I56d8628d223614918a1e5260fdb8a117c8c02dbd
> Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/236344
> Commit-Queue: Harald Alvestrand <hta@webrtc.org>
> Reviewed-by: Niels Moller <nisse@webrtc.org>
> Cr-Commit-Position: refs/heads/main@{#35298}

# Not skipping CQ checks because original CL landed > 1 day ago.

Bug: webrtc:11066
Change-Id: I0c400ceffe1b08e0be7b44abbb54c8a032128f05
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/237223
Reviewed-by: Niels Moller <nisse@webrtc.org>
Reviewed-by: Henrik Boström <hbos@webrtc.org>
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#35312}
2021-11-04 14:46:27 +00:00
Harald Alvestrand
ee212a72f2 Remove code supporting the SDES crypto mode in SDP
Removes the ability to accept nonencrypted answers to encrypted offers.
Fixes some logic around bundled sessions and requirement for
transport parameters.

Bug: webrtc:11066
Change-Id: I56d8628d223614918a1e5260fdb8a117c8c02dbd
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/236344
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Reviewed-by: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#35298}
2021-11-02 12:58:50 +00:00
Harald Alvestrand
1bffe9e885 Cleanup: Move some more protocol names into media_protocol_names
Bug: None
Change-Id: I29ccee993ece01ffbafa85f09abb7cf64dba82d7
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/237020
Reviewed-by: Niels Moller <nisse@webrtc.org>
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#35295}
2021-11-02 11:51:31 +00:00
Artem Titov
880fa8169b Reland "Use backticks not vertical bars to denote variables in comments for /pc"
Original change's description:
> Revert "Use backticks not vertical bars to denote variables in comments for /pc"
>
> This reverts commit 37ee0f5e59.
>
> Reason for revert: Revert in order to be able to revert https://webrtc-review.googlesource.com/c/src/+/225642
>
> Original change's description:
> > Use backticks not vertical bars to denote variables in comments for /pc
> >
> > Bug: webrtc:12338
> > Change-Id: I88cf10afa5fc810b95d2a585ab2e895dcc163b63
> > Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/226953
> > Reviewed-by: Harald Alvestrand <hta@webrtc.org>
> > Commit-Queue: Artem Titov <titovartem@webrtc.org>
> > Cr-Commit-Position: refs/heads/master@{#34575}
>
> TBR=hta@webrtc.org,titovartem@webrtc.org,webrtc-scoped@luci-project-accounts.iam.gserviceaccount.com
>
> Change-Id: I5eddd3a14e1f664bf831e5c294fbc4de5f6a88af
> No-Presubmit: true
> No-Tree-Checks: true
> No-Try: true
> Bug: webrtc:12338
> Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/227082
> Reviewed-by: Björn Terelius <terelius@webrtc.org>
> Commit-Queue: Björn Terelius <terelius@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#34577}

Bug: webrtc:12338
Change-Id: I96bd229b73613c162d11d75fa4f5934e1b4295c7
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/227087
Commit-Queue: Artem Titov <titovartem@webrtc.org>
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#34611}
2021-07-30 22:13:59 +00:00
Björn Terelius
fd05d6f504 Revert "Use backticks not vertical bars to denote variables in comments for /pc"
This reverts commit 37ee0f5e59.

Reason for revert: Revert in order to be able to revert https://webrtc-review.googlesource.com/c/src/+/225642

Original change's description:
> Use backticks not vertical bars to denote variables in comments for /pc
>
> Bug: webrtc:12338
> Change-Id: I88cf10afa5fc810b95d2a585ab2e895dcc163b63
> Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/226953
> Reviewed-by: Harald Alvestrand <hta@webrtc.org>
> Commit-Queue: Artem Titov <titovartem@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#34575}

TBR=hta@webrtc.org,titovartem@webrtc.org,webrtc-scoped@luci-project-accounts.iam.gserviceaccount.com

Change-Id: I5eddd3a14e1f664bf831e5c294fbc4de5f6a88af
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: webrtc:12338
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/227082
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Commit-Queue: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#34577}
2021-07-27 22:10:24 +00:00
Artem Titov
37ee0f5e59 Use backticks not vertical bars to denote variables in comments for /pc
Bug: webrtc:12338
Change-Id: I88cf10afa5fc810b95d2a585ab2e895dcc163b63
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/226953
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Commit-Queue: Artem Titov <titovartem@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#34575}
2021-07-27 20:52:02 +00:00
Harald Alvestrand
7a2db8acbe Modify Bundle logic to not add & destroy extra transport at add-track
If a bundle is established, then per JSEP, the offerer is required to
include the new track in the bundle, and per BUNDLE, the answerer has
to either accept the track as part of the bundle or reject the track;
it cannot move it out of the group. So we will never need the transport.

Bug: webrtc:12837
Change-Id: I41cae74605fecf454900a958776b95607ccf3745
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/221601
Reviewed-by: Henrik Boström <hbos@webrtc.org>
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#34290}
2021-06-15 09:44:36 +00:00
Lennart Grahl
0d0ed76ac1 Fix RTP header extension encryption
Reland of commit a743303211

Previously, RTP header extensions with encryption had been filtered
if the encryption had been activated (not the other way around) which
was likely an unintended logic inversion.

In addition, it ensures that encrypted RTP header extensions are only
negotiated if RTP header extension encryption is turned on. Formerly,
which extensions had been negotiated depended on the order in which
they were inserted, regardless of whether or not header encryption was
actually enabled, leading to no extensions being sent on the wire.

Further changes:

- If RTP header encryption enabled, prefer encrypted extensions over
  non-encrypted extensions
- Add most extensions to list of extensions supported for encryption
- Discard encrypted extensions in a session description in case encryption
  is not supported for that extension
- Mark FindHeaderExtensionByUri without filter argument as deprecated

Bug: webrtc:11713
Change-Id: I52a5ade1b94bc01d1c2a35cb56023684fcaf9982
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/219081
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#34129}
2021-05-26 09:42:09 +00:00
Henrik Boström
f8187e0a82 [Unified Plan] Support multiple BUNDLE groups.
In this CL, JsepTransportController and MediaSessionDescriptionFactory
are updated not to assume that there only exists at most a single BUNDLE
group but a list of N groups. This makes it possible to create multiple
BUNDLE groups by having multiple "a=group:BUNDLE" lines in the SDP.

This makes it possible to have some m= sections in one group and some
other m= sections in another group. For example, you could group all
audio m= sections in one group and all video m= sections in another
group. This enables "send all audio tracks on one transport and all
video tracks on another transport" in Unified Plan. This is something
that was possible in Plan B because all ssrcs in the same m= section
were implicitly bundled together forming a group of audio m= section and
video m= section (even without use of the BUNDLE tag).

PeerConnection will never create multiple BUNDLE groups by default, but
upon setting SDP with multiple BUNDLE groups the PeerConnection will
accept them if configured to accept BUNDLE. This makes it possible to
accept an SFU's BUNDLE offer without having to SDP munge the answer.

C++ unit tests are added. This fix has also been verified manually on:
https://jsfiddle.net/henbos/to89L6ce/43/

Without fix: 0+2 get bundled, 1+3 don't get bundled.
With fix: 0+2 get bundled in first group, 1+3 get bundled in second
group.

Bug: webrtc:10208
Change-Id: Iaf451fa5459c484730c8018274166ef154b19af8
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/214487
Reviewed-by: Taylor <deadbeef@webrtc.org>
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Commit-Queue: Henrik Boström <hbos@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#33838}
2021-04-27 05:53:37 +00:00
Harald Alvestrand
48171ec264 Remove more mentions of RTP datachannels
Bug: webtc:6625
Change-Id: I38c51c4c10df8a5f517733f211e030359d33e787
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/215783
Reviewed-by: Florent Castelli <orphis@webrtc.org>
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#33799}
2021-04-21 10:16:43 +00:00
Harald Alvestrand
7af57c6e48 Remove RTP data implementation
Bug: webrtc:6625
Change-Id: Ie68d7a938d8b7be95a01cca74a176104e4e44e1b
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/215321
Reviewed-by: Henrik Boström <hbos@webrtc.org>
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#33759}
2021-04-16 13:10:54 +00:00
Björn Terelius
24bc419303 Revert "Fix RTP header extension encryption"
This reverts commit a743303211.

Reason for revert: Breaks downstream tests that attempt to call FindHeaderExtensionByUri with 2 arguments. Could you keep the old 2-argument method declaration and just forward the call to the new 3-argument method with a suitable no-op filter?

Original change's description:
> Fix RTP header extension encryption
>
> Previously, RTP header extensions with encryption had been filtered
> if the encryption had been activated (not the other way around) which
> was likely an unintended logic inversion.
>
> In addition, it ensures that encrypted RTP header extensions are only
> negotiated if RTP header extension encryption is turned on. Formerly,
> which extensions had been negotiated depended on the order in which
> they were inserted, regardless of whether or not header encryption was
> actually enabled, leading to no extensions being sent on the wire.
>
> Further changes:
>
> - If RTP header encryption enabled, prefer encrypted extensions over
>   non-encrypted extensions
> - Add most extensions to list of extensions supported for encryption
> - Discard encrypted extensions in a session description in case encryption
>   is not supported for that extension
>
> Note that this depends on https://github.com/cisco/libsrtp/pull/491 to get
> into libwebrtc (cherry-pick or bump libsrtp version). Otherwise, two-byte
> header extensions will prevent any RTP packets being sent/received.
>
> Bug: webrtc:11713
> Change-Id: Ia0779453d342fa11e06996d9bc2d3c826f3466d3
> Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/177980
> Reviewed-by: Harald Alvestrand <hta@webrtc.org>
> Reviewed-by: Taylor <deadbeef@webrtc.org>
> Commit-Queue: Harald Alvestrand <hta@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#33723}

TBR=deadbeef@webrtc.org,terelius@webrtc.org,hta@webrtc.org,lennart.grahl@gmail.com

Change-Id: I7df6b0fa611c6496dccdfb09a65ff33ae4a52b26
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: webrtc:11713
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/215222
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Commit-Queue: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#33727}
2021-04-14 10:10:07 +00:00
Lennart Grahl
a743303211 Fix RTP header extension encryption
Previously, RTP header extensions with encryption had been filtered
if the encryption had been activated (not the other way around) which
was likely an unintended logic inversion.

In addition, it ensures that encrypted RTP header extensions are only
negotiated if RTP header extension encryption is turned on. Formerly,
which extensions had been negotiated depended on the order in which
they were inserted, regardless of whether or not header encryption was
actually enabled, leading to no extensions being sent on the wire.

Further changes:

- If RTP header encryption enabled, prefer encrypted extensions over
  non-encrypted extensions
- Add most extensions to list of extensions supported for encryption
- Discard encrypted extensions in a session description in case encryption
  is not supported for that extension

Note that this depends on https://github.com/cisco/libsrtp/pull/491 to get
into libwebrtc (cherry-pick or bump libsrtp version). Otherwise, two-byte
header extensions will prevent any RTP packets being sent/received.

Bug: webrtc:11713
Change-Id: Ia0779453d342fa11e06996d9bc2d3c826f3466d3
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/177980
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Reviewed-by: Taylor <deadbeef@webrtc.org>
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#33723}
2021-04-14 08:53:45 +00:00
Danil Chapovalov
e904161cec Replace RTC_DEPRECATED with ABSL_DEPRECATED
This remove webrtc-specific macro that has no reason to be webrtc specific
ABSL_DEPRECATED takes a message parameter encouraging to write text how class or function is deprecated.

Bug: webrtc:12484
Change-Id: I89f1398f91dacadc37f7db469dcd985e3724e444
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/208282
Commit-Queue: Danil Chapovalov <danilchap@webrtc.org>
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#33314}
2021-02-22 12:53:23 +00:00
Harald Alvestrand
5761e7b3ff Running apply-iwyu on ~all files in pc/
Bug: none
Change-Id: Ieebdfb743e691f7ae35e1aa354f68ce9e771064d
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/204381
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#33105}
2021-01-29 16:14:10 +00:00
Emil Lundmark
801c9995c8 Signal extmap-allow-mixed by default on session level
The extmap-allow-mixed SDP attribute signals that one- and two-byte RTP
header extensions can be mixed. In practice, this also means that WebRTC
will support two-byte RTP header extensions when this is signaled by
both peers.

Bug: webrtc:9985
Change-Id: I80a3f97bab162c7d9a5acf2cae07b977641c039d
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/197943
Commit-Queue: Emil Lundmark <lndmrk@webrtc.org>
Reviewed-by: Erik Språng <sprang@webrtc.org>
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#33036}
2021-01-19 14:28:11 +00:00
Philipp Hancke
4e8c115960 Reland "introduce an unsupported content description type"
This is a reland of 239f92ecf7

Original change's description:
> introduce an unsupported content description type
>
> This carries around unsupported content descriptions
> (i.e. things where webrtc does not understand the media type
> or protocol) in a special data type so that a rejected content or
> mediasection is added to the answer SDP.
>
> BUG=webrtc:3513
>
> Change-Id: Ifc4168eae11e899f2504649de5e1eecb6801a9fb
> Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/179082
> Reviewed-by: Kári Helgason <kthelgason@webrtc.org>
> Reviewed-by: Harald Alvestrand <hta@webrtc.org>
> Commit-Queue: Philipp Hancke <philipp.hancke@googlemail.com>
> Cr-Commit-Position: refs/heads/master@{#32410}

Bug: webrtc:3513
Change-Id: I48e338100f829f1df5b8165217c89b5ef860fe79
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/188820
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Reviewed-by: Kári Helgason <kthelgason@webrtc.org>
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#32457}
2020-10-21 08:20:05 +00:00
Ilya Nikolaevskiy
ad2ec76387 Revert "introduce an unsupported content description type"
This reverts commit 239f92ecf7.

Reason for revert: Breaks downstream projects.

Original change's description:
> introduce an unsupported content description type
>
> This carries around unsupported content descriptions
> (i.e. things where webrtc does not understand the media type
> or protocol) in a special data type so that a rejected content or
> mediasection is added to the answer SDP.
>
> BUG=webrtc:3513
>
> Change-Id: Ifc4168eae11e899f2504649de5e1eecb6801a9fb
> Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/179082
> Reviewed-by: Kári Helgason <kthelgason@webrtc.org>
> Reviewed-by: Harald Alvestrand <hta@webrtc.org>
> Commit-Queue: Philipp Hancke <philipp.hancke@googlemail.com>
> Cr-Commit-Position: refs/heads/master@{#32410}

TBR=kthelgason@webrtc.org,hta@webrtc.org,philipp.hancke@googlemail.com

Change-Id: I055fe001fe2757d79be7c304eccc43a8e3104f69
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: webrtc:3513
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/188581
Reviewed-by: Ilya Nikolaevskiy <ilnik@webrtc.org>
Commit-Queue: Ilya Nikolaevskiy <ilnik@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#32411}
2020-10-15 10:03:13 +00:00
Philipp Hancke
239f92ecf7 introduce an unsupported content description type
This carries around unsupported content descriptions
(i.e. things where webrtc does not understand the media type
or protocol) in a special data type so that a rejected content or
mediasection is added to the answer SDP.

BUG=webrtc:3513

Change-Id: Ifc4168eae11e899f2504649de5e1eecb6801a9fb
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/179082
Reviewed-by: Kári Helgason <kthelgason@webrtc.org>
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Commit-Queue: Philipp Hancke <philipp.hancke@googlemail.com>
Cr-Commit-Position: refs/heads/master@{#32410}
2020-10-15 09:28:28 +00:00
Taylor Brandstetter
ee8c246be7 Reland "sdp: parse and serialize b=TIAS"
This reverts commit 20b701f3d7.

Reason for reland: Reverting did not affect the test regression.

Original change's description:
> Revert "sdp: parse and serialize b=TIAS"
>
> This reverts commit c6801d4522.
>
> Reason for revert: Speculatively reverting since it possibly breaks downstream performance test.
>
> One issue I noticed is that the correct SDP won't be produced if set_bandwidth_type hasn't been called. Probably should default to b=AS in that case.
>
> Original change's description:
> > sdp: parse and serialize b=TIAS
> >
> > BUG=webrtc:5788
> >
> > Change-Id: I063c756004e4c224fffa36d2800603c7b7e50dce
> > Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/179223
> > Commit-Queue: Philipp Hancke <philipp.hancke@googlemail.com>
> > Reviewed-by: Taylor <deadbeef@webrtc.org>
> > Cr-Commit-Position: refs/heads/master@{#31729}
>
> TBR=deadbeef@webrtc.org,hta@webrtc.org,minyue@webrtc.org,philipp.hancke@googlemail.com,jleconte@webrtc.org
>
> # Not skipping CQ checks because original CL landed > 1 day ago.
>
> Bug: webrtc:5788
> Change-Id: I2a3f676b4359834e511dffd5adedc9388e0ea0f8
> Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/179620
> Reviewed-by: Taylor <deadbeef@webrtc.org>
> Commit-Queue: Taylor <deadbeef@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#31762}

TBR=nisse@webrtc.org

Bug: webrtc:5788
Change-Id: I5c0ef29d275bb2264d9b706b085f7933d59e2801
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/179760
Commit-Queue: Taylor <deadbeef@webrtc.org>
Reviewed-by: Taylor <deadbeef@webrtc.org>
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#31816}
2020-07-30 21:16:08 +00:00
Taylor
20b701f3d7 Revert "sdp: parse and serialize b=TIAS"
This reverts commit c6801d4522.

Reason for revert: Speculatively reverting since it possibly breaks downstream performance test.

One issue I noticed is that the correct SDP won't be produced if set_bandwidth_type hasn't been called. Probably should default to b=AS in that case.

Original change's description:
> sdp: parse and serialize b=TIAS
> 
> BUG=webrtc:5788
> 
> Change-Id: I063c756004e4c224fffa36d2800603c7b7e50dce
> Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/179223
> Commit-Queue: Philipp Hancke <philipp.hancke@googlemail.com>
> Reviewed-by: Taylor <deadbeef@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#31729}

TBR=deadbeef@webrtc.org,hta@webrtc.org,minyue@webrtc.org,philipp.hancke@googlemail.com,jleconte@webrtc.org

# Not skipping CQ checks because original CL landed > 1 day ago.

Bug: webrtc:5788
Change-Id: I2a3f676b4359834e511dffd5adedc9388e0ea0f8
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/179620
Reviewed-by: Taylor <deadbeef@webrtc.org>
Commit-Queue: Taylor <deadbeef@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#31762}
2020-07-17 21:12:17 +00:00
Philipp Hancke
c6801d4522 sdp: parse and serialize b=TIAS
BUG=webrtc:5788

Change-Id: I063c756004e4c224fffa36d2800603c7b7e50dce
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/179223
Commit-Queue: Philipp Hancke <philipp.hancke@googlemail.com>
Reviewed-by: Taylor <deadbeef@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#31729}
2020-07-15 08:01:06 +00:00
Danil Chapovalov
84bb634238 Delete legacy cricket::RtpHeaderExtension struct as unused
Bug: None
Change-Id: I8529475578a91173ca2e89e0bbbf186fc9d39472
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/179222
Reviewed-by: Taylor <deadbeef@webrtc.org>
Reviewed-by: Ilya Nikolaevskiy <ilnik@webrtc.org>
Commit-Queue: Danil Chapovalov <danilchap@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#31722}
2020-07-14 08:55:02 +00:00
Niels Möller
dc80aafe30 Delete SDP x-alt-protocol
Bug: webrtc:9719
Change-Id: I921f72d8e80cc36d62b2aeadfb688a7b884668b6
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/177423
Reviewed-by: Taylor <deadbeef@webrtc.org>
Commit-Queue: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#31547}
2020-06-22 08:11:20 +00:00
Mirko Bonadei
1f0677d01e Remove some TODOs from pc/.
Bug: webrtc:10198
Change-Id: I1782a8ef1248578fcc3ffc8c03b5419225a51350
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/173625
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#31113}
2020-04-20 23:51:16 +00:00
Harald Alvestrand
b97d2fe896 Remove cricket::SessionDescription::Copy()
To be submitted on or after March 13, 2020 (2 weeks after PSA).

Bug: webrtc:10701
Change-Id: Ie4b6d31e1496b81714fe9f9418694fc4c2e69ecd
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/169443
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#30784}
2020-03-13 07:32:41 +00:00
Harald Alvestrand
0fb07f8c90 Deprecate use of cricket::MediaContentDescription::Copy
One should use a std::unique_ptr to the object, as returned
by Clone() instead, not a naked pointer.

Bug: webrtc:10701
Change-Id: I10ab309207f2cb5aec83a6d09336699ed7b26f50
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/169342
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Henrik Boström <hbos@webrtc.org>
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#30646}
2020-02-28 10:03:49 +00:00
Harald Alvestrand
8e7d4bfeef Remove deprecated "description" field of cricket::ContentInfo
Bug: webrtc:10701
Change-Id: I631616fefb59b49603e0a98267b3e58d93edfb50
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/169122
Reviewed-by: Henrik Boström <hbos@webrtc.org>
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#30628}
2020-02-27 14:13:03 +00:00
Harald Alvestrand
8a24c03663 Remove deprecated AddContent function in session_description.h
Bug: webrtc:10701
Change-Id: Ia1b8e5585c777d8f4c308bb8e4baffe752477057
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/168950
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Henrik Boström <hbos@webrtc.org>
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#30615}
2020-02-26 07:49:36 +00:00
Bjorn A Mellem
7a9a092708 Delete media transport integration.
MediaTransport is deprecated and the code is unused.

No-Try: True
Bug: webrtc:9719
Change-Id: I5b864c1e74bf04df16c15f51b8fac3d407331dcd
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/160620
Commit-Queue: Bjorn Mellem <mellem@webrtc.org>
Reviewed-by: Niels Moller <nisse@webrtc.org>
Reviewed-by: Gustaf Ullberg <gustaf@webrtc.org>
Reviewed-by: Åsa Persson <asapersson@webrtc.org>
Reviewed-by: Steve Anton <steveanton@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#29923}
2019-11-26 19:19:36 +00:00
Mirko Bonadei
35214fcfe2 Add missing RTC_EXPORT for the component build.
Bug: webrtc:9419
Change-Id: I3225259fb4cc55e9820f590928795f4587f1e3cb
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/153884
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#29479}
2019-10-15 09:07:44 +00:00
Bjorn A Mellem
8e1343aeda Add an alt-protocol to SDP to indicate which m= sections use a plugin transport.
The plugin transport parameters (a=x-opaque: lines) relate to how to create and
set up a plugin transport.  When SDP bundle is used, the x-opaque line needs to
be copied into the bundled m= section.  This means x-opaque can appear on a
section even if the offerer does not intend to use the transport for the media
described by that section.  Consequently, the answerer cannot currently tell
whether the caller is offering an alternate transport for media, data, or both.

This change adds an a=x-alt-protocol: line to SDP.  The value following this
line matches the <protocol> part of the x-opaque:<protocol>:<params> line.
However, alt-protocol is not bundled--it only ever applies to the m= section
that contains the line.  This allows the offerer to express which m= sections
should actually use an alternate transport, even in the case of bundle.

Note that this is still limited by the available configuration options:
datagram transport can be used for media (audio + video) and/or data.  It is
still not possible to use it for audio but not video, or vice versa.

PeerConnection places an alt-protocol line in each media (audio/video) m=
section if it is configured to use a datagram transport for media.  It places
an alt-protocol line in each data m= section if it is configured to use a
datagram transport for data channels.  PeerConnection leaves alt-protocol in
media (audio/video) m= sections of the answer if it is configured to use a
datagram transport for media, and in data m= sections of the answer if it is
configured to use a datagram transport for data channels.

JsepTransport now negotiates use of the datagram transport independently for
media and data channels.  It only uses it for media if the m= sections for
bundled audio/video have an alt-protocol line matching the x-opaque protocol,
and only uses it for data channels if a bundled m= section for data has an
alt-protocol line matching the x-opaque protocol.

Bug: webrtc:9719
Change-Id: I773e4fc10c57d815afcd76a2a74da38dd0c52b3b
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/154763
Reviewed-by: Steve Anton <steveanton@webrtc.org>
Reviewed-by: Seth Hampson <shampson@webrtc.org>
Commit-Queue: Bjorn Mellem <mellem@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#29351}
2019-09-30 23:10:34 +00:00
Sebastian Jansson
97321b687b Adds test for experimental remote estimate SDP negotiation.
Bug: webrtc:10742
Change-Id: I50d9caecda10c504cb4880c37475eeccd22c0855
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/146705
Reviewed-by: Stefan Holmer <stefan@webrtc.org>
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#28670}
2019-07-24 15:29:24 +00:00
Sebastian Jansson
e1795f4158 Adds remote estimate RTCP packet.
This adds the RemoteEstimate rtcp packet and wires it up to GoogCC where
it's used to improve congestion controller behavior.

The functionality is negotiated using SDP.

It's added with a field trial that allow disabling the functionality in
case there's any issues.

Bug: webrtc:10742
Change-Id: I1ea8e4216a27cd2b00505c99b42d1e38726256c8
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/146602
Reviewed-by: Stefan Holmer <stefan@webrtc.org>
Reviewed-by: Erik Språng <sprang@webrtc.org>
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#28654}
2019-07-24 10:17:26 +00:00
Jonas Olsson
a4d873786f Format almost everything.
This CL was generated by running

git ls-files | grep -P "(\.h|\.cc)$" | grep -v 'sdk/' | grep -v 'rtc_base/ssl_' | \
grep -v 'fake_rtc_certificate_generator.h' | grep -v 'modules/audio_device/win/' | \
grep -v 'system_wrappers/source/clock.cc' | grep -v 'rtc_base/trace_event.h' | \
grep -v 'modules/audio_coding/codecs/ilbc/' | grep -v 'screen_capturer_mac.h' | \
grep -v 'spl_inl_mips.h' | grep -v 'data_size_unittest.cc' | grep -v 'timestamp_unittest.cc' \
| xargs clang-format -i ; git cl format

Most of these changes are clang-format grouping and reordering includes
differently.

Bug: webrtc:9340
Change-Id: Ic83ddbc169bfacd21883e381b5181c3dd4fe8a63
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/144051
Commit-Queue: Jonas Olsson <jonasolsson@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#28505}
2019-07-08 13:45:15 +00:00