Commit graph

174 commits

Author SHA1 Message Date
Sebastian Jansson
d113ee326b Removes deprecated WebRTC-Bwe-AimdRateControl-NetworkState trial.
Bug: webrtc:10498
Change-Id: Ie435ad2e2c73bf2b54d9caccabf9a27443ca4229
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/158082
Reviewed-by: Per Kjellander <perkj@webrtc.org>
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#29596}
2019-10-24 08:14:02 +00:00
Mirko Bonadei
86d053c2db Use source_sets in component builds and static_library in release builds.
Static libraries don't guarantee that an exported symbol gets linked
into a shared library (and in order to support Chromium's component
build mode, WebRTC needs to be linked as a shared library).

Source sets always pass all the object files to the linker.

On the flip side, source_sets link more object files in release builds
and to avoid this, this CL introduces a the GN template "rtc_library" that
expands to static_library during release builds and to source_set during
component builds.

See: https://gn.googlesource.com/gn/+/master/docs/reference.md#func_source_set

Bug: webrtc:9419
Change-Id: I4667e820c2b3fcec417becbd2034acc13e4f04fe
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/157168
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Nico Weber <thakis@chromium.org>
Cr-Commit-Position: refs/heads/master@{#29525}
2019-10-17 21:17:18 +00:00
Per Kjellander
ee153c92fe Send rtcp::RemoteEstimate and rtcp::TransportFeedback in one packet
Change-Id: I53912f4e82a9fd795f8886d6b2cdb313bde08c4d
BUG: webrtc:10742
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/156380
Reviewed-by: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
Commit-Queue: Per Kjellander <perkj@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#29437}
2019-10-10 16:40:39 +00:00
Per Kjellander
52f7ae7c89 Make NetworkStateEstimator injectable in RemoteBitrateEstimator
The NetworkStateEstimator is updated on every incoming RTP packet if available.

A rtcp::RemoteEstimate packet is sent every time a rtcp::TransportFeedback packet is sent.

BUG=webrtc:10742

Change-Id: I4cd8e9d85d35faf76aeefd2e26c2a9fe1a62ca3b
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/152161
Commit-Queue: Per Kjellander <perkj@webrtc.org>
Reviewed-by: Sebastian Jansson <srte@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#29143}
2019-09-10 18:47:36 +00:00
Per Kjellander
f7cb16ff51 Check input parameter in RemoteEstimatorProxy::IncomingPacket without lock
Also inlined RemoteEstimatorProxy::OnPacketArrival

BUG=NONE

Change-Id: I61c94eafb41ea269baeeb0ef13add79672a1488d
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/151909
Reviewed-by: Sebastian Jansson <srte@webrtc.org>
Commit-Queue: Per Kjellander <perkj@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#29109}
2019-09-09 11:51:12 +00:00
Tommi
25eb47ccf1 Make the RtpHeaderParserImpl available to tests and tools only.
There are a few reasons for making this test only:
* The code is only used by tests and utilities.
* The pure interface has only a single implementation so an interface isn't really needed.
  (a followup change could remove it altogether)
* The implementation always incorporates locking regardless of how the class gets used.
  See e.g. previous use in the Packet class.
* The implementation is a layer on top of RtpUtility::RtpHeaderParser which is
  sufficient for most production cases.

Change-Id: Ide6d50567cf8ae5127a2eb04cceeb10cf317ec36
Bug: none
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/150658
Commit-Queue: Tommi <tommi@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#29010}
2019-08-29 15:56:40 +00:00
Oleh Prypin
b1686786e8 Add RTC_ prefix to non-standard format specifier macro "PRIdNS"
Some of the macros in format_macros.h follow the C standard and try to fill holes in it (on Windows). But this one has no direct equivalent in the standard and is just mimicking the naming convention. That's not nice.

References:
https://devblogs.microsoft.com/cppblog/c99-library-support-in-visual-studio-2013/
https://stackoverflow.com/a/2524673

Change-Id: I53f3faca2976a5b5d4b04a67ffb56ae0f4e930b2
Bug: webrtc:10852
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/147862
Commit-Queue: Oleh Prypin <oprypin@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Niels Moller <nisse@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#28794}
2019-08-07 13:36:05 +00:00
Sebastian Jansson
7ea6b290d0 Adds improved estimate bounded backoff to AimdRateControl.
Bug: webrtc:10498
Change-Id: I4e006e437dfa667b738beb009a599bacc6778da5
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/146215
Reviewed-by: Jonas Olsson <jonasolsson@webrtc.org>
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#28632}
2019-07-22 12:22:09 +00:00
Sebastian Jansson
ea3dddf1d0 Use capacity bounds in AimdRateControl if available.
Bug: webrtc:10742
Change-Id: I139f7053d33092efe6430d82596b05c730855383
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/145725
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#28584}
2019-07-17 07:19:38 +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
Mirko Bonadei
79e4c92d70 Remove bwe_rtp_play and add rtp_to_text to the build.
This CL also switches rtp_to_text to ABSL_FLAG.

Bug: webrtc:10616
Change-Id: I6a2ce921e4c622a9fe08e7de724b8c7ed06f3597
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/144630
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#28502}
2019-07-08 11:45:20 +00:00
Sebastian Jansson
b64ad0e72c Using Clock::CurrentTime() where non-test behavior is unchanged.
This CL replaces all uses of Timestamp::us(Clock::TimeInMicroseconds())
with Clock::CurrentTime() which should be a no-op apart from slight
changes in checks.

Additionally instances of Timestamp::ms(Clock::TimeInMilliseconds()) in
test code is replaced. This slightly changes the behavior since the
timestamp will get increased resolution.

Timestamp::ms(Clock::TimeInMilliseconds()) in non-test code is untouched
to avoid changing behavior of production code.

Bug: webrtc:9883
Change-Id: I8047f4cb2ca735f44f11d32f9367aa3eb376ec04
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/142803
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#28321}
2019-06-19 09:18:21 +00:00
Sebastian Jansson
449888ef99 Cleanup of resources from removed remote bitrate estimate test framework.
Bug: webrtc:9883
Change-Id: Id18133a021b3a064b00f0f99b5f30ebb92e89067
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/140945
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#28305}
2019-06-18 10:22:01 +00:00
Sebastian Jansson
3d61ab12e6 Adds send time to ReceivedPacket struct.
Bug: webrtc:10742
Change-Id: I7e83d5ec2e23d1db38d02a0c883466ecdcd387c6
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/141874
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Per Kjellander <perkj@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#28290}
2019-06-14 15:01:36 +00:00
Niels Möller
8169db6df2 Expose target bandwidth fraction for transport feedback for field trial
Bug: None
Change-Id: I5b3db8ff18460ac0bfd5e3db994642a21ba90d9a
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/140944
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Commit-Queue: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#28210}
2019-06-10 12:22:34 +00:00
Sebastian Jansson
12561e06ce Removes legacy remote bitrate estimator test framework.
It isn't actively maintained to be up to date but depends on internals
increasing maintenance burden. There's now better tools available to
evaluate congestion controller performance that should be used if we
want to start maintaining this functionality again.

Bug: webrtc:9883
Change-Id: I097747e6f31a3d1522ef8dfda84f995e33f3a697
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/140887
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#28205}
2019-06-10 09:12:25 +00:00
Erik Språng
d28796209b Distinguish between missing packet and send failure.
This CL introduces three-value enum, in order to be able to distinguish
between send success, send failure, and invalid states such as missing
packet or invalid ssrc.

The behavior is unchanged in this CL, a follow-up will change the pacer
to not consume media budget on invalid states.

Bug: webrtc:8052,webrtc:8975
Change-Id: I1c9e2226f995356daa538d3d3cf44945f35e0133
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/135165
Commit-Queue: Erik Språng <sprang@webrtc.org>
Reviewed-by: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27923}
2019-05-13 10:24:09 +00:00
Niels Möller
780c136523 Move OverUseDetectorOptions out of common_types.h
Moved to modules/remote_bitrate_estimator/overuse_estimator.h.

Bug: webrtc:5876
Change-Id: Iae4b07d94bf4f16b887c3a4129168c4a45a3b5e1
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/135570
Commit-Queue: Niels Moller <nisse@webrtc.org>
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27893}
2019-05-09 13:12:17 +00:00
Niels Möller
2154f751e3 Log transport feedback max interval
To make it easy to see if field trial is in effect.

Bug: None
Change-Id: Id8369061b3222c762a4ea655f7177ce421d66a53
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/135463
Reviewed-by: Stefan Holmer <stefan@webrtc.org>
Commit-Queue: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27865}
2019-05-07 13:43:21 +00:00
Niels Möller
decc07679d Expose send parameters for RemoteEstimatorProxy for field trial.
Bug: None
Change-Id: I14c74f55ed534fff19042423dad63641bd0fa047
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/133187
Commit-Queue: Niels Moller <nisse@webrtc.org>
Reviewed-by: Erik Språng <sprang@webrtc.org>
Reviewed-by: Sebastian Jansson <srte@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27662}
2019-04-17 12:45:47 +00:00
Per Kjellander
416d5db75d Add field trial to AimdRateController to only increase while not in ALR
The idea is that when ALR is detected, the encoder can not produce the bitrate
needed for the delay based estimator to detect overuse and thus the delay based
estimator should not be allowed to increase further.
Likewise, if ALR is not detected, the delay based estimator is allowed to
increase the BWE to ensure that there is no region where the BWE can get stuck.

BUG=webrtc:10542

Change-Id: Ic94b708461c9077fd09132ee4ecb6279ffcd5f99
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/133190
Commit-Queue: Per Kjellander <perkj@webrtc.org>
Reviewed-by: Sebastian Jansson <srte@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27661}
2019-04-17 12:05:24 +00:00
Per Kjellander
494947bbcf Remove direct use of FieldTrials from modules/remote_bitrate_estimator
Instead use WebRtcKeyValueConfig and FieldTrialBasedConfig

BUG=webrtc:10335

Change-Id: Ie148cb466f86d8fa1ded5c7f125fbcccf6e7dbe3
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/132714
Commit-Queue: Per Kjellander <perkj@webrtc.org>
Reviewed-by: Sebastian Jansson <srte@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27642}
2019-04-16 13:23:12 +00:00
Sebastian Jansson
df88cc014a Allow injection of network estimator into GoogCC.
Bug: webrtc:10498
Change-Id: Ie9225411db201dfcfa0a37a3c40992acbdc215bb
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/132402
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Christoffer Rodbro <crodbro@webrtc.org>
Reviewed-by: Stefan Holmer <stefan@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27624}
2019-04-15 14:12:08 +00:00
Ying Wang
0810a7c25a Add base class NetworkPredictor and NetworkPredictorFactory and wire up.
Add base class NetworkPredictor and NetworkPredictorFactory in /api, make it possible to inject customized NetworkPredictor in PeerConnectionFactory level. The NetworkPredictor object will be pass down to GoogCCNetworkControl and DelayBasedBwe.

Bug: webrtc:10492
Change-Id: Iceeadbe1c9388b11ce4ac01ee56554cb0bf64d04
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/130201
Commit-Queue: Ying Wang <yinwa@webrtc.org>
Reviewed-by: Per Kjellander <perkj@webrtc.org>
Reviewed-by: Stefan Holmer <stefan@webrtc.org>
Reviewed-by: Sami Kalliomäki <sakal@webrtc.org>
Reviewed-by: Christoffer Rodbro <crodbro@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27543}
2019-04-10 12:38:58 +00:00
Mirko Bonadei
6a489f22c7 Fully qualify googletest symbols.
Semi-automatically created with:

git grep -l " testing::" | xargs sed -i "s/ testing::/ ::testing::/g"
git grep -l "(testing::" | xargs sed -i "s/(testing::/(::testing::/g"
git cl format

After this, two .cc files failed to compile and I have fixed them
manually.

Bug: webrtc:10523
Change-Id: I4741d3bcedc831b6c5fdc04485678617eb4ce031
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/132018
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27526}
2019-04-09 17:18:20 +00:00
Johannes Kron
f59666b3b2 Fix potential bug due to malformed input
A reasonable amount of incoming packets could generate feedback
for millions of packets.

Bug: chromium:949020
Change-Id: I7f3e6b75b683af5b2732c472cc92c6788540486b
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/131333
Commit-Queue: Johannes Kron <kron@webrtc.org>
Reviewed-by: Sebastian Jansson <srte@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27481}
2019-04-08 11:46:47 +00:00
Johannes Kron
3c15f468c6 Use SeqNumUnwapper to handle reordering of first packets
Fixed todo by replacing SequenceNumberUnwrapper with updated class
SeqNumUnwrapper that correctly handles reordering of early packets.

Bug: webrtc:10263
Change-Id: Iffd93db924fee132d35752996b8d29acbb315d24
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/130498
Reviewed-by: Philip Eliasson <philipel@webrtc.org>
Commit-Queue: Johannes Kron <kron@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27417}
2019-04-02 16:17:32 +00:00
Niels Möller
9d8eaac4ee Delete unneeded direct includes of common_types.h
And delete corresponding dependencies on :webrtc_common. After this
change, common_types.h is included directly only from code in the
following directories:

api/
api/video/
api/video_codecs/
common_video/libyuv/include/
media/base/
modules/remote_bitrate_estimator/
modules/rtp_rtcp/source/
modules/video_coding/codecs/vp9/

There remains plenty of indirect dependencies on the types declared in
common_types.h, but the fewer direct dependencies should make it
easier to find the proper place for each type.

Bug: webrtc:5876
Change-Id: I93e8f214025ecb613c19fdec2015bd3f96c59aae
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/130501
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27376}
2019-04-01 07:18:13 +00:00
Christoffer Rodbro
90d782619e Fix a comment reg. use of field trial.
Bug: none
Change-Id: I284ef1e1b4d0bdaf933646f35176bfd671f9fbc5
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/130200
Reviewed-by: Sebastian Jansson <srte@webrtc.org>
Commit-Queue: Christoffer Rodbro <crodbro@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27347}
2019-03-28 15:41:13 +00:00
Christoffer Rodbro
ed2207abee Introduce a configurable "critical low" bandwidth in AIMD rate control.
When a bandwidth decrease to the estimated throughput would lead to
the "critical low" region we allow dropping to the link capacity
estimate instead (if it is higher).
Also moved BweInitialBackOffInterval config to the same field trial
string.

Bug: webrtc:10462
Change-Id: I4d6ee020a9ab8cede035b64253e3b3b1e2fb92b1
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/129920
Reviewed-by: Sebastian Jansson <srte@webrtc.org>
Commit-Queue: Christoffer Rodbro <crodbro@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27325}
2019-03-27 19:37:05 +00:00
Artem Titov
94b57c044e Cleanup BUILD.gn files from imports like foo:foo
Repalce all occurrences of foo:foo in deps with just foo in BUILD.gn
files.

Done with Sublime regex replace.
Find: \b([-a-zA-Z0-9_]+):+\1\b
In: *.gn
Replace with: \1

Bug: None
Change-Id: I40aba1b14face687a595b852ffe443cb20197611
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/127899
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Commit-Queue: Artem Titov <titovartem@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27225}
2019-03-21 13:05:28 +00:00
Niels Möller
ef1052a134 Reland "Move api/rtp_headers.h to its own build target."
This is a reland of a67050debc

Original change's description:
> Move api/rtp_headers.h to its own build target.
>
> Reduces dependencies on the libjingle_peerconnection_api target from
> lower-level code.
>
> Bug: None
> Change-Id: I98576fc718c396cc0f720c3770acd2b696b9df89
> Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/128565
> Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
> Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
> Commit-Queue: Niels Moller <nisse@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#27213}

Bug: None
Tbr: kwiberg@webrtc.org
Change-Id: If15b05957e50bb8f18a33c2ed1321e672311b626
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/127895
Reviewed-by: Niels Moller <nisse@webrtc.org>
Commit-Queue: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27216}
2019-03-21 09:17:07 +00:00
Steve Anton
2baef3509f Revert "Move api/rtp_headers.h to its own build target."
This reverts commit a67050debc.

Reason for revert: breaks downstream projects

Original change's description:
> Move api/rtp_headers.h to its own build target.
> 
> Reduces dependencies on the libjingle_peerconnection_api target from
> lower-level code.
> 
> Bug: None
> Change-Id: I98576fc718c396cc0f720c3770acd2b696b9df89
> Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/128565
> Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
> Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
> Commit-Queue: Niels Moller <nisse@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#27213}

TBR=danilchap@webrtc.org,kwiberg@webrtc.org,nisse@webrtc.org

Change-Id: I8cccaa8be1700ca8db141db7252eb6ce588ba2e0
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: None
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/128645
Reviewed-by: Steve Anton <steveanton@webrtc.org>
Commit-Queue: Steve Anton <steveanton@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27215}
2019-03-20 16:47:30 +00:00
Niels Möller
a67050debc Move api/rtp_headers.h to its own build target.
Reduces dependencies on the libjingle_peerconnection_api target from
lower-level code.

Bug: None
Change-Id: I98576fc718c396cc0f720c3770acd2b696b9df89
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/128565
Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27213}
2019-03-20 16:00:49 +00:00
Mirko Bonadei
1ddc7634fd Qualify cmath functions.
Bug: None
Change-Id: Id561750eb6c2e26588e505beb3800e97075adb87
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/127782
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27130}
2019-03-14 13:09:34 +00:00
Niels Möller
70a83949b7 Delete use of WebRtcRTPHeader from FEC test code
Tbr: srte@webrtc.org # comment change in modules/remote_bitrate_estimator/
Bug: webrtc:10397
Change-Id: Ic30e724c18c8812810ac7a608b7065d56a7676e8
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/126941
Commit-Queue: Niels Moller <nisse@webrtc.org>
Reviewed-by: Rasmus Brandt <brandtr@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27069}
2019-03-12 09:40:02 +00:00
Johannes Kron
0da25a1c8e Update TransportSequenceNumberV2 extension to support fixed size
The initial implementation forced the sender to use different sizes
of the RTP header extension depending on if a feedback request is
included or not. This can be a problem if the RTP header is pre-
allocated.
This CL changes this so that a static size of 4 bytes can be used
for the TransportSequenceNumberV2 RTP header extension. The change
in the protocol to get this to work is that
FeedbackRequest::sequence_count == 0 means that no feedback is
requested, and FeedbackRequest::sequence_count == 1 means that
feedback is requested for the current packet only.

Bug: webrtc:10262
Change-Id: Ia5134b3daf49f8a5b89f6c717894f6e055f39c8e
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/125420
Commit-Queue: Johannes Kron <kron@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26985}
2019-03-06 09:08:11 +00:00
Mirko Bonadei
fc52b912a3 Implicitly suppress //build/config/clang:find_bad_constructs.
Since there is no way to enable/disable these diagnostics at runtime,
this CL moves the suppression into the rtc_* templates in order to
remove the need to explicitly add the snippet of code needed to
suppress it (currently copy/pasted in 144 locations).

The diagnostic that causes the most problems is the one about "complex
class/struct explicit ctor/dtor" [1] because WebRTC doesn't find
it useful enough.

Other diagnostics are good (for example the one that warns about
using "virtual" instead of "override", but that will be covered by
this clang-tidy check [2]) while others are Chromium related so
they have never triggered.

[1] - https://cs.chromium.org/chromium/src/tools/clang/plugins/FindBadConstructsConsumer.cpp?l=147-167&rcl=b4bebe1aa15dba7ca5fcc6456a81a55665327c3a
[2] - https://clang.llvm.org/extra/clang-tidy/checks/modernize-use-override.html

Bug: webrtc:163
Change-Id: Icbf27efa5b369100a31e6a32df1a0913729b3b34
Reviewed-on: https://webrtc-review.googlesource.com/c/125088
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26918}
2019-03-01 10:18:17 +00:00
Johannes Kron
599d59237a Extend RemoteEstimatorProxy to support feedback on sender request.
Bug: webrtc:10263
Change-Id: I85b992eff7d1e7ed66ead4745f346ddad2977e8e
Reviewed-on: https://webrtc-review.googlesource.com/c/120800
Commit-Queue: Johannes Kron <kron@webrtc.org>
Reviewed-by: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Erik Språng <sprang@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26752}
2019-02-19 13:56:44 +00:00
Johannes Kron
7ff164e6e1 Plumbing of feedback on request setting
Bug: webrtc:10263
Change-Id: I23c09e680d6381598e4172b76025ff84f33aa4de
Reviewed-on: https://webrtc-review.googlesource.com/c/121422
Reviewed-by: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Stefan Holmer <stefan@webrtc.org>
Reviewed-by: Erik Språng <sprang@webrtc.org>
Commit-Queue: Johannes Kron <kron@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26606}
2019-02-08 10:54:21 +00:00
Mirko Bonadei
c84f661b10 Stop using Googletest legacy APIs.
Googletest recently started replacing the term Test Case by Test Suite.
From now on, the preferred API is TestSuite*; the older TestCase* API
will be slowly deprecated.

This CL moves WebRTC to the new set of APIs.

More info in [1].

This CL has been generated with this script:

declare -A items
items[TYPED_TEST_CASE]=TYPED_TEST_SUITE
items[TYPED_TEST_CASE_P]=TYPED_TEST_SUITE_P
items[REGISTER_TYPED_TEST_CASE_P]=REGISTER_TYPED_TEST_SUITE_P
items[INSTANTIATE_TYPED_TEST_CASE_P]=INSTANTIATE_TYPED_TEST_SUITE_P
items[INSTANTIATE_TEST_CASE_P]=INSTANTIATE_TEST_SUITE_P
for i in "${!items[@]}"
do
  git ls-files | xargs sed -i "s/\b$i\b/${items[$i]}/g"
done
git cl format

[1] - https://github.com/google/googletest/blob/master/googletest/docs/primer.md#beware-of-the-nomenclature

Bug: None
Change-Id: I5ae191e3046caf347aeee01554d5743548ab0e3f
Reviewed-on: https://webrtc-review.googlesource.com/c/118701
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26494}
2019-01-31 13:23:33 +00:00
Sebastian Jansson
aa01f27667 Removes all const Clock*.
This prepares for making the Clock interface fully mutable.

Calls to the time functions in Clock can have side effects in some
circumstances. It's also questionable if it's a good idea to allow
repeated calls to a const method return different values without
any changed to the class instance.

Bug: webrtc:9883
Change-Id: I96fb9230705f7c80a4c0702132fd9dc73899fc5e
Reviewed-on: https://webrtc-review.googlesource.com/c/120347
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26467}
2019-01-30 13:03:37 +00:00
Mirko Bonadei
fe055c197a [clang-tidy] Apply modernize-use-override fixes.
This CL applies clang-tidy's modernize-use-override [1] to the
WebRTC codebase.

All changes in this CL are automatically generated by both clang-tidy
and 'git cl format'.

[1] - https://clang.llvm.org/extra/clang-tidy/checks/modernize-use-override.html

Bug: webrtc:10252
Change-Id: I2bb8bd90fa8adb90aa33861fe7c788132a819a20
Reviewed-on: https://webrtc-review.googlesource.com/c/120412
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26461}
2019-01-30 09:26:17 +00:00
Mirko Bonadei
649a4c2ea3 [clang-tidy] Apply performance-inefficient-vector-operation fixes.
This CL applies clang-tidy's performance-inefficient-vector-operation
[1] on the WebRTC codebase.

All changes in this CL are automatically generated by both clang-tidy
and 'git cl format'.

[1] - https://clang.llvm.org/extra/clang-tidy/checks/performance-inefficient-vector-operation.html

Bug: webrtc:10252
Change-Id: I824caab2a5746036852e00d714b89aa5ec030ee3
Reviewed-on: https://webrtc-review.googlesource.com/c/120052
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26442}
2019-01-29 09:45:21 +00:00
Mirko Bonadei
37ec55e2bb [clang-tidy] Apply performance-faster-string-find fixes.
This CL applies clang-tidy's performance-faster-string-find [1] on the
WebRTC codebase.

All changes in this CL are automatically generated by both clang-tidy
and 'git cl format'.

[1] - https://clang.llvm.org/extra/clang-tidy/checks/performance-faster-string-find.html

Bug: webrtc:10252
Change-Id: I4b8c0396836f3c325488e37d97037fa04742a5d2
Reviewed-on: https://webrtc-review.googlesource.com/c/120047
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26423}
2019-01-28 11:31:53 +00:00
Sebastian Jansson
470a5eae93 Introduces common AudioAllocationSettings class.
This class collects the field trial based configuration of audio
allocation and bandwidth in one place. This makes it easier
overview and prepares for future cleanup of the trials.

Bug: webrtc:9718
Change-Id: I34a441c0165b423f1e2ee63894337484684146ac
Reviewed-on: https://webrtc-review.googlesource.com/c/118282
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Oskar Sundbom <ossu@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26370}
2019-01-23 12:13:29 +00:00
Sebastian Jansson
05acd2b76f Removes clock from TransportFeedbackAdapter.
Instead timestamps required for processing are provided explicitly.
This makes it easier to ensure correct usage in log processing
and simulation.

Bug: webrtc:10170
Change-Id: I724a6b9b94e83caa22b8e43b63ef4e6b46138e6a
Reviewed-on: https://webrtc-review.googlesource.com/c/118702
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26339}
2019-01-21 12:55:00 +00:00
Sebastian Jansson
95edb037a4 Adds WebRtcKeyValueConfig interface
The WebRtcKeyValueConfig interface allows providing custom key value
configurations that changes per instance of GoogCcNetworkController.

Bug: webrtc:10009
Change-Id: I520fff030d1c3c755455ec8f67896fe8a6b4d970
Reviewed-on: https://webrtc-review.googlesource.com/c/116989
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Per Kjellander <perkj@webrtc.org>
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26312}
2019-01-18 08:45:08 +00:00
Steve Anton
10542f21c8 (4) Rename files to snake_case: update BUILD.gn, include paths, header guards, and DEPS entries
Mechanically generated by running this command:

tools_webrtc/do-renames.sh update all-renames.txt && git cl format

Then manually updating:

tools_webrtc/sanitizers/tsan_suppressions_webrtc.cc

Bug: webrtc:10159
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Change-Id: I54824cd91dada8fc3ee3d098f971bc319d477833
Reviewed-on: https://webrtc-review.googlesource.com/c/115653
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26226}
2019-01-11 17:11:39 +00:00
Christoffer Rodbro
c7dbd5ac08 Renamed a variable in overuse_detector.
Bug: webrtc:9933
Change-Id: I6f3ad101b69f36d280c5783f30d5f03f730aecce
Reviewed-on: https://webrtc-review.googlesource.com/c/115942
Reviewed-by: Stefan Holmer <stefan@webrtc.org>
Commit-Queue: Christoffer Rodbro <crodbro@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26113}
2019-01-02 16:43:12 +00:00