Commit Graph

26625 Commits

Author SHA1 Message Date
06c51455fc Adds support for VP9 scalability layers to scenario tests.
Bug: webrtc:9510
Change-Id: I8d2823114bc921ed3412e3abda5501ce73f5a6fb
Reviewed-on: https://webrtc-review.googlesource.com/c/123042
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Erik Språng <sprang@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26743}
2019-02-18 18:05:22 +00:00
9c31ac2323 Tests for multi-stream Opus.
This CL (mainly) adds bit-exactness tests for multi-stream Opus. The
tests are in audio_coding_unittest.cc. Some refactoring of
AcmSendTestOldApi, AcmSenderBitExactnessOldApi is done to make it
possible. A few checks for "channels \in {1, 2}" are replaced with
"channels \in {1, 2, 4, 6, 8}" in the WebRTC Opus codec wrapper. A few
other changes are made to be able to write and read multi-channel WAV
files.

The SDP changes are NOT included; as of this CL there is no way to set
up a multi-stream opus en/de-coder from SDP strings.

Bug: webrtc:8649
Change-Id: I1d93a9b8eecc3f6e19896ff2e2ce9b63da77a23c
Reviewed-on: https://webrtc-review.googlesource.com/c/114883
Reviewed-by: Oskar Sundbom <ossu@webrtc.org>
Commit-Queue: Alex Loiko <aleloi@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26742}
2019-02-18 17:09:59 +00:00
f2727fb8d3 Adds slides support to scenario tests.
Bug: webrtc:9510
Change-Id: I793fb9dbacc916b7b1a95d2fd30683d17a37f1b5
Reviewed-on: https://webrtc-review.googlesource.com/c/123041
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Erik Språng <sprang@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26741}
2019-02-18 16:24:40 +00:00
e9652ca6ec Android: Add video processing interface
This CL adds an API for injecting video processing after the WebRTC
CPU and QP scaling step.

Bug: webrtc:10247
Change-Id: I776498e1e9113f50e953ee411bbb31f181863312
Reviewed-on: https://webrtc-review.googlesource.com/c/119953
Commit-Queue: Magnus Jedvert <magjed@webrtc.org>
Reviewed-by: Sami Kalliomäki <sakal@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26740}
2019-02-18 15:46:42 +00:00
4a2d57ac43 Don't include video_bitrate_allocation.h from encoded_image.h
The needed constant kMaxSpatialLayers is now moved to
video_codec_constants.h.

Bug: webrtc:8311
Change-Id: Iefde2e0668ce6a8d262d2747ad497ae8891873f9
Reviewed-on: https://webrtc-review.googlesource.com/c/123181
Reviewed-by: Erik Språng <sprang@webrtc.org>
Commit-Queue: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26739}
2019-02-18 14:05:27 +00:00
71aee3a116 Reland "Propagate VideoFrame::UpdateRect to encoder"
Reland with fixes for failing chromium tests.

Propagate VideoFrame::UpdateRect to encoder

Accumulate it in all places where frames can be dropped before they reach the encoder.

Reset UpdateRect in VideoBroadcaster if frame the previous frame is dropped.
No accumulation is done here since it's supposed to be a brief occasion then configuration have changed.

Original Reviewed-on: https://webrtc-review.googlesource.com/c/123102

Bug: webrtc:10310
Change-Id: I18be73f47f227d6392bf9cb220b549ced225714f
Reviewed-on: https://webrtc-review.googlesource.com/c/123230
Reviewed-by: Niels Moller <nisse@webrtc.org>
Reviewed-by: Ilya Nikolaevskiy <ilnik@webrtc.org>
Commit-Queue: Ilya Nikolaevskiy <ilnik@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26738}
2019-02-18 13:44:14 +00:00
f873cd9cdf Roll chromium_revision 26c36e3408..0f484ff968 (632825:633071)
Change log: 26c36e3408..0f484ff968
Full diff: 26c36e3408..0f484ff968

Changed dependencies
* src/base: 1946b941ce..2661fd9a16
* src/build: 66a84f0d61..11b5de2694
* src/buildtools: 106e9fce37..6b05562fca
* src/ios: 322a2a0310..0c499c8a4c
* src/testing: 8874a419c7..d4f8a56efa
* src/third_party: 1708b4bdfb..5d278b44df
* src/third_party/catapult: https://chromium.googlesource.com/catapult.git/+log/1f97ac96e6..ede50ff4d8
* src/third_party/depot_tools: efc7e91fa7..5c00a22f22
* src/third_party/ow2_asm: 0dcaea8bd839b3f2eb8415c327b40e8e398a373e..NNAhdJzMdnutUVqfSJm5v0tVazA9l3Dd6CRwH6N4Q5kC
* src/third_party/robolectric: Q-aurrjcIq02dl2ws-M-IhnIydurvTbUMR_xD_zBJ0YC..iRFT1e5YFmRn5cbV0cAkQ5vDUXFmQ4qPYqStmmDfiMMC
* src/third_party/robolectric/robolectric: 7e067f1112..3d6dcabf55
* src/tools: 71e14e34ff..fb9973f4bc
DEPS diff: 26c36e3408..0f484ff968/DEPS

No update to Clang.

TBR=chromium-webrtc-autoroll@webrtc-ci.iam.gserviceaccount.com,
BUG=None

Change-Id: Iec40b6aefb35f67b5256466a3f78d9a155f9b992
Reviewed-on: https://webrtc-review.googlesource.com/c/123340
Reviewed-by: Autoroller <chromium-webrtc-autoroll@webrtc-ci.iam.gserviceaccount.com>
Commit-Queue: Autoroller <chromium-webrtc-autoroll@webrtc-ci.iam.gserviceaccount.com>
Cr-Commit-Position: refs/heads/master@{#26737}
2019-02-18 13:32:47 +00:00
bf47495979 Update remaining audio test code to not use WebRtcRTPHeader.
Bug: webrtc:5876
Change-Id: I5b1abcec4a0ef52b6dd36d1fe94dbfd3f88f28a7
Reviewed-on: https://webrtc-review.googlesource.com/c/123235
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26736}
2019-02-18 13:29:35 +00:00
a0b1fb9ac7 Pass H264 profile/level settings to codec.
Bug: none
Change-Id: I0587a3d7c12a779a968b8c392c3dfa91b4ad040a
Reviewed-on: https://webrtc-review.googlesource.com/c/123180
Reviewed-by: Rasmus Brandt <brandtr@webrtc.org>
Reviewed-by: Ilya Nikolaevskiy <ilnik@webrtc.org>
Commit-Queue: Sergey Silkin <ssilkin@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26735}
2019-02-18 13:06:35 +00:00
3073c728ac Fix AndroidVideoDecoderTest for new Robolectric version.
New Robolectric version doesn't allow Surface to be constructed with a
null SurfaceTexture.

Bug: webrtc:10323
Change-Id: Ib6991d40b12b81d16ecb04787945cc4045e99b40
Reviewed-on: https://webrtc-review.googlesource.com/c/123236
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Magnus Jedvert <magjed@webrtc.org>
Commit-Queue: Sami Kalliomäki <sakal@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26734}
2019-02-18 12:56:42 +00:00
e049eba27c Revert "Add Sender and Receiver interfaces for MediaTransport audio"
This reverts commit 0d8eed6ac77fadf7f9bcf70c671710d60b1ee62d.

Reason for revert: crashes of unit tests.

Original change's description:
> Add Sender and Receiver interfaces for MediaTransport audio
> 
> Implement in LoopbackMediaTransport.
> 
> Bug: webrtc:9719
> Change-Id: I429ac3f78d99b8ea4f9ac85b9a3600b215b61a55
> Reviewed-on: https://webrtc-review.googlesource.com/c/121957
> Commit-Queue: Niels Moller <nisse@webrtc.org>
> Reviewed-by: Fredrik Solenberg <solenberg@webrtc.org>
> Reviewed-by: Bjorn Mellem <mellem@webrtc.org>
> Reviewed-by: Anton Sukhanov <sukhanov@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#26731}

TBR=solenberg@webrtc.org,nisse@webrtc.org,mellem@webrtc.org,sukhanov@webrtc.org,psla@webrtc.org,sukhanov@google.com

Change-Id: I02e409e1bbe2b2dea8a7b1aa08fa44d4146bda8f
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: webrtc:9719
Reviewed-on: https://webrtc-review.googlesource.com/c/123232
Reviewed-by: Sergey Silkin <ssilkin@webrtc.org>
Commit-Queue: Sergey Silkin <ssilkin@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26733}
2019-02-18 09:52:40 +00:00
d2f04360a6 Make sdk/android:{audio,video}_api_java publicly visible.
Bug: None
Change-Id: I7a2b4d643fa776b4bf2ab3a4860bbc8892dc1a86
Reviewed-on: https://webrtc-review.googlesource.com/c/123229
Reviewed-by: Magnus Jedvert <magjed@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26732}
2019-02-18 09:03:11 +00:00
0d8eed6ac7 Add Sender and Receiver interfaces for MediaTransport audio
Implement in LoopbackMediaTransport.

Bug: webrtc:9719
Change-Id: I429ac3f78d99b8ea4f9ac85b9a3600b215b61a55
Reviewed-on: https://webrtc-review.googlesource.com/c/121957
Commit-Queue: Niels Moller <nisse@webrtc.org>
Reviewed-by: Fredrik Solenberg <solenberg@webrtc.org>
Reviewed-by: Bjorn Mellem <mellem@webrtc.org>
Reviewed-by: Anton Sukhanov <sukhanov@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26731}
2019-02-18 08:51:26 +00:00
6e1402b25f Skip SSIM calculation in real time mode.
SSIM calculation is not optimized. It takes ~100ms to process 720p frame
on Galaxy S8.

Bug: none
Change-Id: I51cc26d81124f06b2dfb27814edf2e4ae58141ce
Reviewed-on: https://webrtc-review.googlesource.com/c/121762
Reviewed-by: Rasmus Brandt <brandtr@webrtc.org>
Commit-Queue: Sergey Silkin <ssilkin@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26730}
2019-02-18 08:49:47 +00:00
afb5dbbf4e Update ACM to use RTPHeader instead of WebRtcRTPHeader
Bug: webrtc:5876
Change-Id: Id3311dcf508cca34495349197eeac2edf8783772
Reviewed-on: https://webrtc-review.googlesource.com/c/123188
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26729}
2019-02-18 08:01:31 +00:00
389b1672a3 Delete test/constants.h
It's not possible to use constants.h for all RTP extensions
after the number of extensions exceeds 14, which is the maximum
number of one-byte RTP extensions. This is because some extensions
would have to be assigned a number greater than 14, even if the
test only involves 14 extensions or less.

For uniformity's sake, this CL also edits some files to use an
enum as the files involved in this CL, rather than free-floating
const-ints.

Bug: webrtc:10288
Change-Id: Ib5e58ad72c4d3756f4c4f6521f140ec59617f3f5
Reviewed-on: https://webrtc-review.googlesource.com/c/123048
Commit-Queue: Elad Alon <eladalon@webrtc.org>
Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Erik Språng <sprang@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26728}
2019-02-17 21:47:41 +00:00
8d2e228991 Add thread safety annotations for PeerConnection::*_state_
Plus all the annotations that are necessary to make things compile
again.

Bug: webrtc:9987
Change-Id: If7bbd5a468a8c50ac3cfe03cd2ed4f5b5f461195
Reviewed-on: https://webrtc-review.googlesource.com/c/123047
Commit-Queue: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Steve Anton <steveanton@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26727}
2019-02-17 13:02:33 +00:00
e45c688e67 Remove webrtc::ProtoString.
Bug: None
Change-Id: If99a977532eda41eada25f57ff0ff6fe17085986
Reviewed-on: https://webrtc-review.googlesource.com/c/122581
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Minyue Li <minyue@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26726}
2019-02-16 11:11:45 +00:00
eaf6a8cbc8 Adding src/third_party/androidx to the DEPS file.
Starting from [1], Robolectric requires androidx. This CL is needed
in order to unblock the Chromium roll into WebRTC [2].

[1] - https://chromium-review.googlesource.com/c/1436148
[2] - https://webrtc-review.googlesource.com/c/src/+/123284/

TBR=oprypin@webrtc.org

Bug: None
Change-Id: I6e36c242d72577c5eb27acba8d07d94b859607ae
Reviewed-on: https://webrtc-review.googlesource.com/c/123226
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26725}
2019-02-16 09:47:40 +00:00
7ea460593c Add latency to remote source api.
Latency corresponds to base minimum delay on NetEq.

Bug: webrtc:10287
Change-Id: I538d202e3e4fe07b779c46bf560e2fde38e0468e
Reviewed-on: https://webrtc-review.googlesource.com/c/121704
Commit-Queue: Ruslan Burakov <kuddai@google.com>
Reviewed-by: Steve Anton <steveanton@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26724}
2019-02-16 02:13:44 +00:00
86f09741a7 Roll chromium_revision 7df1a5ba86..26c36e3408 (632711:632825)
Change log: 7df1a5ba86..26c36e3408
Full diff: 7df1a5ba86..26c36e3408

Changed dependencies
* src/base: c05941fc24..1946b941ce
* src/build: 6543247e82..66a84f0d61
* src/ios: 095f8faa44..322a2a0310
* src/testing: 03c31b32d0..8874a419c7
* src/third_party: 3a01810a82..1708b4bdfb
* src/third_party/catapult: https://chromium.googlesource.com/catapult.git/+log/798bb03c89..1f97ac96e6
* src/third_party/depot_tools: 2b14855de9..efc7e91fa7
* src/tools: e133deffad..71e14e34ff
DEPS diff: 7df1a5ba86..26c36e3408/DEPS

No update to Clang.

TBR=chromium-webrtc-autoroll@webrtc-ci.iam.gserviceaccount.com,
BUG=None

Change-Id: I1c982f38f67a6dd112e3e86ade6e0ff060cf4fcb
Reviewed-on: https://webrtc-review.googlesource.com/c/123281
Reviewed-by: Autoroller <chromium-webrtc-autoroll@webrtc-ci.iam.gserviceaccount.com>
Commit-Queue: Autoroller <chromium-webrtc-autoroll@webrtc-ci.iam.gserviceaccount.com>
Cr-Commit-Position: refs/heads/master@{#26723}
2019-02-16 01:30:16 +00:00
c6643141f9 Clean up implementation in stream_params
Bug: None
Change-Id: I49c8a4b09c7d01e7b2e6a1cdcc2c90b83cfeddb8
Reviewed-on: https://webrtc-review.googlesource.com/c/121602
Reviewed-by: Amit Hilbuch <amithi@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26722}
2019-02-15 23:13:19 +00:00
ca890ee582 Revert "Fix getStats() freeze bug affecting Chromium but not WebRTC standalone."
This reverts commit 05d43c6f7fe497fed0f2c8714e2042dd07a86df2.

Reason for revert: It breaks some Chromium trybots:
https://ci.chromium.org/p/chromium/builders/luci.chromium.try/linux_chromium_asan_rel_ng/206387
https://ci.chromium.org/p/chromium/builders/luci.chromium.try/linux_chromium_tsan_rel_ng/207737
https://ci.chromium.org/p/chromium/builders/luci.chromium.try/win10_chromium_x64_rel_ng/202283

Original change's description:
> Fix getStats() freeze bug affecting Chromium but not WebRTC standalone.
> 
> PeerConnection::Close() is, per-spec, a blocking operation.
> Unfortunately, PeerConnection is implemented to own resources used by
> the network thread, and Close() - on the signaling thread - destroys
> these resources. As such, tasks run in parallel like getStats() get into
> race conditions with Close() unless synchronized. The mechanism in-place
> is RTCStatsCollector::WaitForPendingRequest(), it waits until the
> network thread is done with the in-parallel stats request.
> 
> Prior to this CL, this was implemented by performing
> rtc::Thread::ProcessMessages() in a loop until the network thread had
> posted a task on the signaling thread to say that it was done which
> would then get processed by ProcessMessages(). In WebRTC this works, and
> the test is RTCStatsIntegrationTest.GetsStatsWhileClosingPeerConnection.
> 
> But because Chromium's thread wrapper does no support
> ProcessMessages(), calling getStats() followed by close() in Chrome
> resulted in waiting forever (https://crbug.com/850907).
> 
> In this CL, the process messages loop is removed. Instead, the shared
> resources are guarded by an rtc::Event. WaitForPendingRequest() still
> blocks the signaling thread, but only while shared resources are in use
> by the network thread. After this CL, calling WaitForPendingRequest() no
> longer has any unexpected side-effects since it no longer processes
> other messages that might have been posted on the thread.
> 
> The resource ownership and threading model of WebRTC deserves to be
> revisited, but this fixes a common Chromium crash without redesigning
> PeerConnection, in a way that does not cause more blocking than what
> the other PeerConnection methods are already doing.
> 
> Note: An alternative to using rtc::Event is to use resource locks and
> to not perform the stats collection on the network thread if the
> request was cancelled before the start of processing, but this has very
> little benefit in terms of performance: once the network thread starts
> collecting the stats, it would use the lock until collection is
> completed, blocking the signaling thread trying to acquire that lock
> anyway. This defeats the purpose and is a riskier change, since
> cancelling partial collection in this inherently racy edge-case would
> have observable differences from the returned stats, which may cause
> more regressions.
> 
> Bug: chromium:850907
> Change-Id: Idceeee0bddc0c9d5518b58a2b263abb2bbf47cff
> Reviewed-on: https://webrtc-review.googlesource.com/c/121567
> Commit-Queue: Henrik Boström <hbos@webrtc.org>
> Reviewed-by: Steve Anton <steveanton@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#26707}

TBR=steveanton@webrtc.org,hbos@webrtc.org

Change-Id: Icd82cdd5bd086a90999f7fd5f8616e1f2d2153bf
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: chromium:850907
Reviewed-on: https://webrtc-review.googlesource.com/c/123225
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26721}
2019-02-15 21:10:54 +00:00
ca3c8017e5 Minor eventlogvisualizer tweaks.
- Clarify sequence number plot.
- Add pacer_delay plot to plot profile 'all'.

Bug: none
Change-Id: Ib009481cfd8858bee556d5d28610bc0c65a6859c
Reviewed-on: https://webrtc-review.googlesource.com/c/123101
Commit-Queue: Konrad Hofbauer <hofbauer@webrtc.org>
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26720}
2019-02-15 21:05:04 +00:00
429b67db1f Revert "Propagate VideoFrame::UpdateRect to encoder"
This reverts commit efa72a1312e9871c9b33b7a1fec208b379608898.

Reason for revert: It seems to break come chromium.webrtc.fyi bots:

They are all release.

https://ci.chromium.org/p/chromium/builders/luci.chromium.webrtc.fyi/WebRTC%20Chromium%20FYI%20Linux%20Tester/2167
https://ci.chromium.org/p/chromium/builders/luci.chromium.webrtc.fyi/WebRTC%20Chromium%20FYI%20Mac%20Tester/1833
https://ci.chromium.org/p/chromium/builders/luci.chromium.webrtc.fyi/WebRTC%20Chromium%20FYI%20Win10%20Tester/1835

Original change's description:
> Propagate VideoFrame::UpdateRect to encoder
> 
> Accumulate it in all places where frames can be dropped before they reach
> the encoder.
> 
> Reset UpdateRect in VideoBroadcaster if frame the previous frame is dropped.
> No accumulation is done here since it's supposed to be a brief occusion then
> configuration have changed.
> 
> Bug: webrtc:10310
> Change-Id: I2813ecd009eb730bd99ffa0a02f979091b56bf80
> Reviewed-on: https://webrtc-review.googlesource.com/c/123102
> Commit-Queue: Ilya Nikolaevskiy <ilnik@webrtc.org>
> Reviewed-by: Niels Moller <nisse@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#26711}

TBR=ilnik@webrtc.org,nisse@webrtc.org,sprang@webrtc.org

Change-Id: If34b5440393fffba6c37cd80c02e2b419b7ec601
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: webrtc:10310
Reviewed-on: https://webrtc-review.googlesource.com/c/123224
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26719}
2019-02-15 21:00:17 +00:00
675b47d543 Roll chromium_revision bf2d75ba40..7df1a5ba86 (632595:632711)
Change log: bf2d75ba40..7df1a5ba86
Full diff: bf2d75ba40..7df1a5ba86

Changed dependencies
* src/base: c55a7c83d4..c05941fc24
* src/build: 74bb357c65..6543247e82
* src/ios: 54e6fbc061..095f8faa44
* src/testing: b5e8334f08..03c31b32d0
* src/third_party: 493a51d585..3a01810a82
* src/third_party/catapult: https://chromium.googlesource.com/catapult.git/+log/309c28a632..798bb03c89
* src/tools: 67c88ad6be..e133deffad
DEPS diff: bf2d75ba40..7df1a5ba86/DEPS

No update to Clang.

TBR=chromium-webrtc-autoroll@webrtc-ci.iam.gserviceaccount.com,
BUG=None

Change-Id: I77b0e8fe91f2b024e109d0cff733c3c457b7ef00
Reviewed-on: https://webrtc-review.googlesource.com/c/123240
Reviewed-by: Autoroller <chromium-webrtc-autoroll@webrtc-ci.iam.gserviceaccount.com>
Commit-Queue: Autoroller <chromium-webrtc-autoroll@webrtc-ci.iam.gserviceaccount.com>
Cr-Commit-Position: refs/heads/master@{#26718}
2019-02-15 19:37:24 +00:00
9775a58a76 Plot bitrate allocation per layer based on RTCP XR target bitrate.
Bug: webrtc:10312
Change-Id: Ic0221e71d27d1fdc35c50a93e7e2303953c4fbf5
Reviewed-on: https://webrtc-review.googlesource.com/c/123222
Reviewed-by: Mirta Dvornicic <mirtad@webrtc.org>
Commit-Queue: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26717}
2019-02-15 18:32:55 +00:00
b03ab7107c Add thread safety annotation for PeerConnection::event_log_
Plus all the annotations that are necessary to make things compile
again.

Bug: webrtc:9987
Change-Id: I68a51bfa3342c6d66d67276d5979144af34692c9
Reviewed-on: https://webrtc-review.googlesource.com/c/123046
Reviewed-by: Steve Anton <steveanton@webrtc.org>
Commit-Queue: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26716}
2019-02-15 18:31:50 +00:00
744310fcea Add thread safety annotation for PeerConnection::observer_ and factory_
Plus all the annotations that are necessary to make things compile
again.

(The latter could only be made const, since it is accessed from both
the signal thread and the worker thread.)

Bug: webrtc:9987
Change-Id: I49f1568d26a327f48cd94c2c70bc5939e9fbd59a
Reviewed-on: https://webrtc-review.googlesource.com/c/122842
Reviewed-by: Steve Anton <steveanton@webrtc.org>
Commit-Queue: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26715}
2019-02-15 17:17:51 +00:00
7c974e61be Plot RTCP types for incoming and outgoing RTCP packets.
Bug: webrtc:10312
Change-Id: I9908f9c0a6f419a36bb25ad8f15afb5e29de0f03
Reviewed-on: https://webrtc-review.googlesource.com/c/122884
Commit-Queue: Björn Terelius <terelius@webrtc.org>
Reviewed-by: Mirta Dvornicic <mirtad@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26714}
2019-02-15 17:13:29 +00:00
c39f462b2d Move RtcEventProbeClusterCreated to the network controller.
Originally RtcEventProbeClusterCreated was logged in bitrate prober. This means that anyone who was using GoogCcNetworkControl wasn't logging it, and the NetworkControl wasn't self-contained.
This changes moves the responsibility for logging ProbeClusterCreated to ProbeController (where the probe is created), it also moves the responsibility for assigning probe ids to the probe controller.

Bug: None
Change-Id: If0433cc6d311b5483ea3980749b03ddbcd2bf041
Reviewed-on: https://webrtc-review.googlesource.com/c/122927
Commit-Queue: Peter Slatala <psla@webrtc.org>
Reviewed-by: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26713}
2019-02-15 16:42:47 +00:00
6255af99a8 Fix RateCounter to don't fail if there are too small amount of events
Bug: webrtc:10138
Change-Id: Iac26e4948b92810245c16b8c46b4b3e70850505e
Reviewed-on: https://webrtc-review.googlesource.com/c/123193
Commit-Queue: Artem Titov <titovartem@webrtc.org>
Commit-Queue: Ilya Nikolaevskiy <ilnik@webrtc.org>
Reviewed-by: Ilya Nikolaevskiy <ilnik@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26712}
2019-02-15 16:28:05 +00:00
efa72a1312 Propagate VideoFrame::UpdateRect to encoder
Accumulate it in all places where frames can be dropped before they reach
the encoder.

Reset UpdateRect in VideoBroadcaster if frame the previous frame is dropped.
No accumulation is done here since it's supposed to be a brief occusion then
configuration have changed.

Bug: webrtc:10310
Change-Id: I2813ecd009eb730bd99ffa0a02f979091b56bf80
Reviewed-on: https://webrtc-review.googlesource.com/c/123102
Commit-Queue: Ilya Nikolaevskiy <ilnik@webrtc.org>
Reviewed-by: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26711}
2019-02-15 15:42:34 +00:00
3a656d14dc Tune bitrates and minQP thresholds for high-fps screenshare.
Raise MinQP to allow easier steady-state convergence.

Update SVC rate allocator to not waste bandwidth if there's not enough
for the highest layer.

Bug: webrtc:10257
Change-Id: Iba937bf3c224ffed256308bdb6434be8b5223f84
Reviewed-on: https://webrtc-review.googlesource.com/c/122843
Reviewed-by: Sergey Silkin <ssilkin@webrtc.org>
Commit-Queue: Ilya Nikolaevskiy <ilnik@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26710}
2019-02-15 15:13:57 +00:00
c8221fc610 Roll chromium_revision d1f68eb66e..bf2d75ba40 (632477:632595)
Change log: d1f68eb66e..bf2d75ba40
Full diff: d1f68eb66e..bf2d75ba40

Changed dependencies
* src/base: 32407e1dea..c55a7c83d4
* src/build: 383614544b..74bb357c65
* src/ios: 877c8752bb..54e6fbc061
* src/third_party: 4063eb822e..493a51d585
* src/third_party/catapult: https://chromium.googlesource.com/catapult.git/+log/778eee0740..309c28a632
* src/tools: 0d447c418e..67c88ad6be
DEPS diff: d1f68eb66e..bf2d75ba40/DEPS

No update to Clang.

TBR=chromium-webrtc-autoroll@webrtc-ci.iam.gserviceaccount.com,
BUG=None

Change-Id: I8d032e4045119de4b2edfc8bec24229ad90e077a
Reviewed-on: https://webrtc-review.googlesource.com/c/123211
Reviewed-by: Autoroller <chromium-webrtc-autoroll@webrtc-ci.iam.gserviceaccount.com>
Commit-Queue: Autoroller <chromium-webrtc-autoroll@webrtc-ci.iam.gserviceaccount.com>
Cr-Commit-Position: refs/heads/master@{#26709}
2019-02-15 13:32:22 +00:00
075f6877bd Add struct for feedback request to RTPHeaderExtension
Bug: webrtc:10262
Change-Id: I88b8f2ea79bc94c9675f2e393ff7d0869ba478e6
Reviewed-on: https://webrtc-review.googlesource.com/c/123049
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Johannes Kron <kron@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26708}
2019-02-15 12:05:03 +00:00
05d43c6f7f Fix getStats() freeze bug affecting Chromium but not WebRTC standalone.
PeerConnection::Close() is, per-spec, a blocking operation.
Unfortunately, PeerConnection is implemented to own resources used by
the network thread, and Close() - on the signaling thread - destroys
these resources. As such, tasks run in parallel like getStats() get into
race conditions with Close() unless synchronized. The mechanism in-place
is RTCStatsCollector::WaitForPendingRequest(), it waits until the
network thread is done with the in-parallel stats request.

Prior to this CL, this was implemented by performing
rtc::Thread::ProcessMessages() in a loop until the network thread had
posted a task on the signaling thread to say that it was done which
would then get processed by ProcessMessages(). In WebRTC this works, and
the test is RTCStatsIntegrationTest.GetsStatsWhileClosingPeerConnection.

But because Chromium's thread wrapper does no support
ProcessMessages(), calling getStats() followed by close() in Chrome
resulted in waiting forever (https://crbug.com/850907).

In this CL, the process messages loop is removed. Instead, the shared
resources are guarded by an rtc::Event. WaitForPendingRequest() still
blocks the signaling thread, but only while shared resources are in use
by the network thread. After this CL, calling WaitForPendingRequest() no
longer has any unexpected side-effects since it no longer processes
other messages that might have been posted on the thread.

The resource ownership and threading model of WebRTC deserves to be
revisited, but this fixes a common Chromium crash without redesigning
PeerConnection, in a way that does not cause more blocking than what
the other PeerConnection methods are already doing.

Note: An alternative to using rtc::Event is to use resource locks and
to not perform the stats collection on the network thread if the
request was cancelled before the start of processing, but this has very
little benefit in terms of performance: once the network thread starts
collecting the stats, it would use the lock until collection is
completed, blocking the signaling thread trying to acquire that lock
anyway. This defeats the purpose and is a riskier change, since
cancelling partial collection in this inherently racy edge-case would
have observable differences from the returned stats, which may cause
more regressions.

Bug: chromium:850907
Change-Id: Idceeee0bddc0c9d5518b58a2b263abb2bbf47cff
Reviewed-on: https://webrtc-review.googlesource.com/c/121567
Commit-Queue: Henrik Boström <hbos@webrtc.org>
Reviewed-by: Steve Anton <steveanton@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26707}
2019-02-15 11:16:11 +00:00
914351de5c Reland "Always offer transport sequence number header extension for audio""
(reverted in https://webrtc-review.googlesource.com/c/src/+/123182/1)

Original cl description:
Always offer transport sequence number header extension for audio

If the extension is negotiated, it will only be used if
the field trial WebRTC-Audio-SendSideBwe is enabled.
This allows simpler experimentation if it should be used or not.

Patchset 3 contain the only change:
  Add the field trial WebRTC-Audio-SendSideBwe to  call/rampup_tests.cc

TBR: srte@webrtc.org,ossu@webrtc.org
Bug: webrtc:10309 webrtc:10286
Change-Id: I2c1224e8a9fab52c1030369c1364686322e88a0f
Reviewed-on: https://webrtc-review.googlesource.com/c/123183
Commit-Queue: Per Kjellander <perkj@webrtc.org>
Reviewed-by: Erik Språng <sprang@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26706}
2019-02-15 10:57:38 +00:00
106d92d4c9 Add thread safety annotation for PeerConnection::SignalDataChannelCreated_
Plus all the annotations that are necessary to make things compile
again.

Bug: webrtc:9987
Change-Id: I53caa3c6644c5d0fcb50f7c1e89e853eddd769a5
Reviewed-on: https://webrtc-review.googlesource.com/c/122882
Reviewed-by: Steve Anton <steveanton@webrtc.org>
Commit-Queue: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26705}
2019-02-15 10:49:48 +00:00
13bc8713af PostMessageWithFunctor() added.
This function is used to post messages onto rtc::Threads. The thread
invokes the functor without blocking the calling thread. Messages posted
in this way are executed in the order that they were posted. This is
meant to work as the equivalent of "thread->PostTask()" in Chromium.

Note: AsyncInvoker currently does something similar but it is more
cumbersome to use (somebody has to create it and own it and make sure
not to destroy it while tasks are pending or else they're cancelled). It
also comes with a fundamental flaw: You cannot destroy the AsyncInvoker
from within the functor (this results in a neverending Wait). This makes
the AsyncInvoker not suitable for implementing "destructor traits"
amongst other things.

This CL will allow us to easily add "PostTask()" to rtc::Thread or add
support for DestructorTraits, which is especially useful when you have a
reference counted object that is referenced from multiple threads but
owns resources that has to be destroyed on a particular thread.

Blocking invokes are forbidden in Chromium but WebRTC performs them
frequently. Being able to perform the equivalent of PostTask() is a
good thing.

Bug: webrtc:10293
Change-Id: Ie2a612059a783f18ddf98cff6edb7fce447fb5be
Reviewed-on: https://webrtc-review.googlesource.com/c/121408
Commit-Queue: Henrik Boström <hbos@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Reviewed-by: Steve Anton <steveanton@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26704}
2019-02-15 10:00:18 +00:00
397c06fe9d Revert "Always offer transport sequence number header extension for audio"
This reverts commit fd965c008c7bc395bb276f260262ac11ccd25406.

Reason for revert: Cause test failure.

Original change's description:
> Always offer transport sequence number header extension for audio
> 
> If the extension is negotiated, it will only be used if
> the field trial WebRTC-Audio-SendSideBwe is enabled.
> This allows simpler experimentation if it should be used or not.
> 
> Bug: webrtc:10309 webrtc:10286
> Change-Id: I797e6f14c06d46189e40f6d09805c2e09afc015b
> Reviewed-on: https://webrtc-review.googlesource.com/c/122542
> Commit-Queue: Per Kjellander <perkj@webrtc.org>
> Reviewed-by: Erik Språng <sprang@webrtc.org>
> Reviewed-by: Sebastian Jansson <srte@webrtc.org>
> Reviewed-by: Oskar Sundbom <ossu@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#26689}

TBR=ossu@webrtc.org,sprang@webrtc.org,srte@webrtc.org,perkj@webrtc.org

Change-Id: I1b7d3fa5c282a5bf049ca54695ad16c8278a2698
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: webrtc:10309 webrtc:10286
Reviewed-on: https://webrtc-review.googlesource.com/c/123182
Reviewed-by: Ying Wang <yinwa@webrtc.org>
Commit-Queue: Ying Wang <yinwa@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26703}
2019-02-15 08:53:25 +00:00
7e0e44f8b4 Move video-related MediaTransport interfaces to their own file and target
Bug: webrtc:9719
Change-Id: I2cf4a8520ce5c07c76ab0310cf7ab0ab285d9e0c
Reviewed-on: https://webrtc-review.googlesource.com/c/122504
Reviewed-by: Peter Slatala <psla@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Commit-Queue: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26702}
2019-02-15 08:17:20 +00:00
054db54ec4 Remove an absl::WrapUnique usage without absl/memory/memory.h include
absl::WrapUnique requires memory.h include on C++17 mode compile.

Bug: chromium:752720
Change-Id: Iaa958652727c8927831d8eecd223678328c7b3bd
Reviewed-on: https://webrtc-review.googlesource.com/c/122440
Commit-Queue: Taiju Tsuiki <tzik@chromium.org>
Reviewed-by: Peter Slatala <psla@webrtc.org>
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26701}
2019-02-15 04:39:06 +00:00
22997d66b8 Roll chromium_revision 2ad52fb2a4..d1f68eb66e (632357:632477)
Change log: 2ad52fb2a4..d1f68eb66e
Full diff: 2ad52fb2a4..d1f68eb66e

Changed dependencies
* src/base: 61c98912a6..32407e1dea
* src/build: f7f21da60d..383614544b
* src/ios: f9421ecdbc..877c8752bb
* src/testing: 3a16217f2b..b5e8334f08
* src/third_party: 0b6da2cdde..4063eb822e
* src/third_party/catapult: https://chromium.googlesource.com/catapult.git/+log/754352edf2..778eee0740
* src/third_party/depot_tools: 452a49f4b6..2b14855de9
* src/tools: 7df6c9fa94..0d447c418e
DEPS diff: 2ad52fb2a4..d1f68eb66e/DEPS

No update to Clang.

TBR=chromium-webrtc-autoroll@webrtc-ci.iam.gserviceaccount.com,
BUG=None

Change-Id: Ibc0e2b3aca2255bab886c326ef4a9b7f4ea00d28
Reviewed-on: https://webrtc-review.googlesource.com/c/123203
Reviewed-by: Autoroller <chromium-webrtc-autoroll@webrtc-ci.iam.gserviceaccount.com>
Commit-Queue: Autoroller <chromium-webrtc-autoroll@webrtc-ci.iam.gserviceaccount.com>
Cr-Commit-Position: refs/heads/master@{#26700}
2019-02-15 03:32:52 +00:00
1c9c9fc9b6 Replace replace_substrs with Abseil
Bug: None
Change-Id: I155cc29db951ef1b812691c57aaafe037fbeb230
Reviewed-on: https://webrtc-review.googlesource.com/c/114241
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Commit-Queue: Steve Anton <steveanton@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26699}
2019-02-15 01:22:54 +00:00
bf9e01ab4e Add support of fast media sending in peer connection e2e test
Start sending media from the peer when it's ICE connection state is
connected.

Bug: webrtc:10138
Change-Id: I9f5a1cd917317a3ebadd7c156563035b0bbecf2a
Reviewed-on: https://webrtc-review.googlesource.com/c/121956
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Peter Slatala <psla@webrtc.org>
Commit-Queue: Artem Titov <titovartem@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26698}
2019-02-15 00:51:03 +00:00
ceba6ae2a7 Return a copy, becase GetPercentile in SamplesStatsCounter isn't const
Bug: webrtc:10138
Change-Id: I2ec2ce4765e514bfd065f094f5905233e5f4f9cd
Reviewed-on: https://webrtc-review.googlesource.com/c/123043
Reviewed-by: Peter Slatala <psla@webrtc.org>
Commit-Queue: Artem Titov <titovartem@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26697}
2019-02-15 00:49:58 +00:00
cf8405e172 Add generic packet rates to event_log_visualizer.
This change adds incoming & outgoing packet rates to the
event_log_visualizer.

The outgoing packet rate is drawn on the graph with outgoing RTP rate,
because we want to see it together with bandwidth estimate and probe
clusters.

The incoming packet rate is drawn separately.

Bug: webrtc:9719
Change-Id: I32648d016359af110837440ed1a5f9c31c841ea7
Reviewed-on: https://webrtc-review.googlesource.com/c/122941
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Reviewed-by: Bjorn Mellem <mellem@webrtc.org>
Commit-Queue: Peter Slatala <psla@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26696}
2019-02-14 22:45:37 +00:00
15653f957d Roll chromium_revision 78de17c053..2ad52fb2a4 (632252:632357)
Change log: 78de17c053..2ad52fb2a4
Full diff: 78de17c053..2ad52fb2a4

Changed dependencies
* src/base: 54b55a6d77..61c98912a6
* src/build: aa4d830c69..f7f21da60d
* src/ios: 09cc36ceb7..f9421ecdbc
* src/testing: d27b16e080..3a16217f2b
* src/third_party: a1daa5f638..0b6da2cdde
* src/third_party/catapult: https://chromium.googlesource.com/catapult.git/+log/b3d62293b2..754352edf2
* src/third_party/depot_tools: 3b1e64245a..452a49f4b6
* src/tools: d624e46558..7df6c9fa94
DEPS diff: 78de17c053..2ad52fb2a4/DEPS

No update to Clang.

TBR=chromium-webrtc-autoroll@webrtc-ci.iam.gserviceaccount.com,
BUG=None

Change-Id: I44157d102180bef546ee256bd821f8f5b075b172
Reviewed-on: https://webrtc-review.googlesource.com/c/123160
Reviewed-by: Autoroller <chromium-webrtc-autoroll@webrtc-ci.iam.gserviceaccount.com>
Commit-Queue: Autoroller <chromium-webrtc-autoroll@webrtc-ci.iam.gserviceaccount.com>
Cr-Commit-Position: refs/heads/master@{#26695}
2019-02-14 22:02:43 +00:00
aa58415bfa Reland "Enabling Simulcast use via AddTransceiver."
This is a reland of ce470aab518f067a67aa03aaab1fc61a45afa0ec

Original change's description:
> Enabling Simulcast use via AddTransceiver.
> 
> This change removes the restriction on multiple send encodings when
> calling AddTransceiver. If RIDs are not provided in the
> simulcast scenario, they are auto-generated by the platform.
> 
> This effectively enables the use of spec-compliant simulcast.
> Tests are also added to verify simulcast functionality.
> 
> Bug: webrtc:10075
> Change-Id: I088feba70a26e85abcc7bfbe3ea1fe5103cd47d2
> Reviewed-on: https://webrtc-review.googlesource.com/c/121389
> Reviewed-by: Florent Castelli <orphis@webrtc.org>
> Reviewed-by: Steve Anton <steveanton@webrtc.org>
> Commit-Queue: Amit Hilbuch <amithi@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#26590}

Bug: webrtc:10075
Change-Id: Ib4392e36d5d60b966ecff56d4df69bf60d13a73d
Reviewed-on: https://webrtc-review.googlesource.com/c/122962
Reviewed-by: Amit Hilbuch <amithi@webrtc.org>
Reviewed-by: Steve Anton <steveanton@webrtc.org>
Commit-Queue: Amit Hilbuch <amithi@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26694}
2019-02-14 20:58:34 +00:00