|
Interface RTCRtpReceiver and RTCPeerConnection.getReceivers() added.
This CL adds RTCPeerConnection.getReceivers() and a partial
implementation of the RTCRtpReceiver interface, only containing the
track member. Behind experimental RuntimeEnabled feature
"RTCRtpReceiver".
getReceivers() spec:
https://w3c.github.io/webrtc-pc/#dom-rtcpeerconnection-getreceivers
RTCRtpReceiver spec:
https://w3c.github.io/webrtc-pc/#rtcrtpreceiver-interface
blink layer:
- javascript object RTCRtpReceiver.[idl/h/cpp] added.
- interface WebRTCRtpReceiver.[h/cpp] added.
- interface WebRTCPeerConnectionHandler::getReceivers() added.
content layer:
- RTCRtpReceiver.[h/cc] added (implementation of WebRTCRtpReceiver).
- RTCPeerConnectionHandler::getReceivers() added (implementation of
WebRTCPeerConnectionHandler implementation).
All remote tracks have receivers. When receivers are surfaced we find
which upper-layer track to reference by iterating remote tracks.
New receivers are created on getReceivers(), inactive receivers are
removed on didRemoveRemoteStream(). We should be able to create
receivers at the same time that tracks are created but on
didAddRemoteStream() they are not fully initialized which creates
problems. I left a TODO, we should use events for when tracks are
being added/removed, not streams, but that is a separate issue. (The
spec is moving away from streams in favor of addTrack/removeTrack.)
Testing:
- rtc_peer_connection_handler_unittest.cc: Tests the
RTCPeerConnectionHandler::getReceivers implementation.
- RTCPeerConnection-getReceivers.html: A LayoutTest testing adding and
removing streams and that receivers match. Uses a
MockRTCPeerConnectionHandler to add and remove streams (fake call).
- webrtc_rtp_browsertest.cc / peerconnection_rtp.js: Sets up a call
between two tabs and verifies remote tracks and receivers match,
tests the full stack in a real browser.
BUG= chromium:703122
Review-Url: https://codereview.chromium.org/2759953003
Cr-Commit-Position: refs/heads/master@{#460793}
Committed: https://chromium.googlesource.com/chromium/src/+/cc4863010c8c9b706274a1eeed803d5a3f8250ca
Total comments: 8
Total comments: 14
Total comments: 27
Total comments: 2
|
Unified diffs |
Side-by-side diffs |
Delta from patch set |
Stats (+1006 lines, -6 lines) |
Patch |
|
M |
chrome/browser/media/webrtc/webrtc_browsertest_base.h
|
View
|
|
2 chunks |
+6 lines, -0 lines |
0 comments
|
Download
|
|
M |
chrome/browser/media/webrtc/webrtc_browsertest_base.cc
|
View
|
|
1 chunk |
+18 lines, -0 lines |
0 comments
|
Download
|
|
A |
chrome/browser/media/webrtc/webrtc_rtp_browsertest.cc
|
View
|
|
1 chunk |
+51 lines, -0 lines |
0 comments
|
Download
|
|
M |
chrome/test/BUILD.gn
|
View
|
1
2
3
4
|
2 chunks |
+2 lines, -0 lines |
0 comments
|
Download
|
|
A |
chrome/test/data/webrtc/peerconnection_rtp.js
|
View
|
|
1 chunk |
+106 lines, -0 lines |
0 comments
|
Download
|
|
M |
chrome/test/data/webrtc/webrtc_jsep01_test.html
|
View
|
|
1 chunk |
+1 line, -0 lines |
0 comments
|
Download
|
|
M |
content/renderer/BUILD.gn
|
View
|
1
2
3
4
5
6
|
1 chunk |
+2 lines, -0 lines |
0 comments
|
Download
|
|
M |
content/renderer/media/mock_peer_connection_impl.h
|
View
|
|
1 chunk |
+2 lines, -0 lines |
0 comments
|
Download
|
|
M |
content/renderer/media/mock_peer_connection_impl.cc
|
View
|
|
3 chunks |
+54 lines, -0 lines |
0 comments
|
Download
|
|
M |
content/renderer/media/rtc_peer_connection_handler.h
|
View
|
|
2 chunks |
+9 lines, -0 lines |
0 comments
|
Download
|
|
M |
content/renderer/media/rtc_peer_connection_handler.cc
|
View
|
1
2
3
4
5
6
|
4 chunks |
+76 lines, -0 lines |
0 comments
|
Download
|
|
M |
content/renderer/media/rtc_peer_connection_handler_unittest.cc
|
View
|
1
2
3
4
|
3 chunks |
+53 lines, -0 lines |
0 comments
|
Download
|
|
A |
content/renderer/media/webrtc/rtc_rtp_receiver.h
|
View
|
1
2
3
4
5
6
7
|
1 chunk |
+43 lines, -0 lines |
0 comments
|
Download
|
|
A |
content/renderer/media/webrtc/rtc_rtp_receiver.cc
|
View
|
|
1 chunk |
+54 lines, -0 lines |
0 comments
|
Download
|
|
M |
content/shell/test_runner/mock_webrtc_peer_connection_handler.h
|
View
|
|
2 chunks |
+3 lines, -0 lines |
0 comments
|
Download
|
|
M |
content/shell/test_runner/mock_webrtc_peer_connection_handler.cc
|
View
|
1
2
3
4
|
4 chunks |
+58 lines, -0 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/LayoutTests/external/wpt/webrtc/rtcpeerconnection/rtcpeerconnection-idl-expected.txt
|
View
|
|
3 chunks |
+3 lines, -3 lines |
0 comments
|
Download
|
|
A |
third_party/WebKit/LayoutTests/fast/peerconnection/RTCPeerConnection-getReceivers.html
|
View
|
1
2
3
4
5
|
1 chunk |
+216 lines, -0 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/LayoutTests/webexposed/global-interface-listing-expected.txt
|
View
|
1
2
3
4
|
3 chunks |
+6 lines, -0 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/modules/modules_idl_files.gni
|
View
|
1
2
3
4
|
1 chunk |
+1 line, -0 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/modules/peerconnection/BUILD.gn
|
View
|
1
2
3
4
|
1 chunk |
+2 lines, -0 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/modules/peerconnection/RTCPeerConnection.h
|
View
|
1
2
3
|
5 chunks |
+13 lines, -0 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/modules/peerconnection/RTCPeerConnection.cpp
|
View
|
1
2
3
4
5
6
|
6 chunks |
+53 lines, -0 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/modules/peerconnection/RTCPeerConnection.idl
|
View
|
1
|
1 chunk |
+3 lines, -0 lines |
0 comments
|
Download
|
|
A |
third_party/WebKit/Source/modules/peerconnection/RTCRtpReceiver.h
|
View
|
1
2
3
4
5
|
1 chunk |
+37 lines, -0 lines |
0 comments
|
Download
|
|
A |
third_party/WebKit/Source/modules/peerconnection/RTCRtpReceiver.cpp
|
View
|
1
2
3
4
5
|
1 chunk |
+27 lines, -0 lines |
0 comments
|
Download
|
|
A |
third_party/WebKit/Source/modules/peerconnection/RTCRtpReceiver.idl
|
View
|
|
1 chunk |
+12 lines, -0 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/platform/BUILD.gn
|
View
|
1
2
3
4
5
6
|
1 chunk |
+1 line, -0 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/platform/RuntimeEnabledFeatures.json5
|
View
|
1
2
3
4
5
6
|
1 chunk |
+4 lines, -0 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/platform/exported/WebMediaStream.cpp
|
View
|
|
2 chunks |
+30 lines, -3 lines |
0 comments
|
Download
|
|
A |
third_party/WebKit/Source/platform/exported/WebRTCRtpReceiver.cpp
|
View
|
|
1 chunk |
+11 lines, -0 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/Source/web/tests/ActiveConnectionThrottlingTest.cpp
|
View
|
|
2 chunks |
+5 lines, -0 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/public/BUILD.gn
|
View
|
1
2
3
4
5
6
|
1 chunk |
+1 line, -0 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/public/platform/WebMediaStream.h
|
View
|
|
1 chunk |
+6 lines, -0 lines |
0 comments
|
Download
|
|
M |
third_party/WebKit/public/platform/WebRTCPeerConnectionHandler.h
|
View
|
1
2
|
3 chunks |
+6 lines, -0 lines |
0 comments
|
Download
|
|
A |
third_party/WebKit/public/platform/WebRTCRtpReceiver.h
|
View
|
1
2
|
1 chunk |
+31 lines, -0 lines |
0 comments
|
Download
|
Total messages: 70 (53 generated)
|