44 Commits

Author SHA1 Message Date
Magnus Jedvert
f45381e1e5 VideoCapturerAndroid: Report onFirstFrameAvailable() for textures as well
We currently only trigger onFirstFrameAvailable() for byte buffer frames.

R=perkj@webrtc.org

Review URL: https://codereview.webrtc.org/1701993002 .

Cr-Commit-Position: refs/heads/master@{#11670}
2016-02-18 14:47:55 +00:00
Magnus Jedvert
5199c74d25 AndroidVideoCapturer getSupportedFormats(): Change interface from JSON string to List/vector
This CL simplifies the VideoCapturer interface from 'String getSupportedFormatsAsJson() throws JSONException' to 'List<CaptureFormat> getSupportedFormats()'. The intermediate conversion to/from a JSON string is removed, and AndroidVideoCapturerJni converts the Java list to a C++ vector directly instead.

BUG=webrtc:5519
R=perkj@webrtc.org

Review URL: https://codereview.webrtc.org/1702603002 .

Cr-Commit-Position: refs/heads/master@{#11669}
2016-02-18 12:10:02 +00:00
magjed
347c0bb5b5 Android GLShader: Check return value of glCreateShader()
This CL adds a check to see if the return value of GLES20.glCreateShader() is zero. Also, shaders are flagged for deletion immediately after glLinkProgram() instead of doing it in release().

BUG=b/27197590

Review URL: https://codereview.webrtc.org/1702953002

Cr-Commit-Position: refs/heads/master@{#11668}
2016-02-18 11:47:52 +00:00
Per
fd22e6cf2d Change PeerConnectionFactory.setVideoHwAccelerationOptions to be able to replace Egl context.
BUG=b/27222102
R=glaznev@webrtc.org

Review URL: https://codereview.webrtc.org/1707933003 .

Cr-Commit-Position: refs/heads/master@{#11666}
2016-02-18 10:36:01 +00:00
deadbeef
9d3584c47e Implementing unified plan encoding of msid.
Meaning "a=msid:...", instead of "a=ssrc:X msid:...".
An additional option to SdpSerialize determines if the
"a=msid" attribute is used.

Review URL: https://codereview.webrtc.org/1688383002

Cr-Commit-Position: refs/heads/master@{#11644}
2016-02-17 01:54:16 +00:00
honghaiz
e1a0c942d6 Add network cost as part of the connection ranking.
For now, the network cost is purely based on the network type (cellular has cost 0xFFFF and everything else has cost 0).
Add cost to the candidate signaling and the stun request signaling (which is needed for peer reflexive candidates).
BUG=webrtc:4325

Review URL: https://codereview.webrtc.org/1668073002

Cr-Commit-Position: refs/heads/master@{#11642}
2016-02-16 22:55:01 +00:00
perkj
461121c67b Replaced eglbase_jni with with holding a EglBase in PeerConnectionFactory.
Review URL: https://codereview.webrtc.org/1695763002

Cr-Commit-Position: refs/heads/master@{#11627}
2016-02-15 14:28:40 +00:00
Magnus Jedvert
5e7834e151 Android: Make VideoCapturer an interface for all VideoCapturers to implement
This CL factors out the interface that AndroidVideoCapturerJni is using to communicate with the Java counterpart. This interface is moved into VideoCapturer. The interface is not touched in this CL, and a follow-up CL is planned to simplify and improve it.

Another change is that the native part of VideoCapturer is created in PeerConnectionFactory.createVideoSource() instead of doing it immediately in the ctor.

BUG=webrtc:5519
R=perkj@webrtc.org

Review URL: https://codereview.webrtc.org/1696553003 .

Cr-Commit-Position: refs/heads/master@{#11606}
2016-02-12 16:05:36 +00:00
Per
a50924115e This reland https://codereview.webrtc.org/1655793003/ with the change that cricket::VideoCapturer::SignalVideoFrame is added back and used for frame forwarding. It is used in Chrome remoting.
BUG=webrtc:5426
R=pthatcher@webrtc.org
TBR=pthatcher@webrtc.org for moved channelmanager....

Review URL: https://codereview.webrtc.org/1689923002 .

Cr-Commit-Position: refs/heads/master@{#11597}
2016-02-12 12:31:08 +00:00
nisse
51542be8ce Introduce struct MediaConfig, with construction-time settings.
Pass it to MediaController constructor and down to WebRtcVideoEngine2
and WebRtcVoiceEngine.

Follows discussion on https://codereview.webrtc.org/1646253004/

TBR=pthatcher@webrtc.org
BUG=webrtc:5438

Review URL: https://codereview.webrtc.org/1670153003

Cr-Commit-Position: refs/heads/master@{#11595}
2016-02-12 10:27:12 +00:00
kjellander@webrtc.org
9b8df25c73 Move talk/session/media -> webrtc/pc
The libjingle_p2p target is renamed to rtc_pc.
The libjingle_p2p_unittest test will be renamed in a
separate follow-up CL, to make it possible to run all
trybots successfully for this CL.

BUG=webrtc:5419
R=deadbeef@webrtc.org, pthatcher@webrtc.org, tommi@webrtc.org

Review URL: https://codereview.webrtc.org/1691463002 .

Cr-Commit-Position: refs/heads/master@{#11592}
2016-02-12 05:48:10 +00:00
kjellander@webrtc.org
5ad129741c Rename webrtc/media/webrtc -> webrtc/media/engine
BUG=webrtc:5420
NOTRY=True
R=pthatcher@google.com, pthatcher@webrtc.org

Review URL: https://codereview.webrtc.org/1684163002 .

Cr-Commit-Position: refs/heads/master@{#11591}
2016-02-12 05:39:50 +00:00
hjon
f396f6085f Update API for Objective-C RTCPeerConnection.
BUG=

Review URL: https://codereview.webrtc.org/1640993002

Cr-Commit-Position: refs/heads/master@{#11590}
2016-02-12 00:19:10 +00:00
kwiberg
8fb3557052 rtc::Buffer: Replace an internal rtc::scoped_ptr with std::unique_ptr
We'd like to completely replace rtc::scoped_ptr with std::unique_ptr.
This is a first trial CL to see if using unique_ptr causes any
problems.

(As a side effect of removing the scoped_ptr.h include in buffer.h,
I had to fix broken includes in no less than three files.)

BUG=webrtc:5520

Review URL: https://codereview.webrtc.org/1687833006

Cr-Commit-Position: refs/heads/master@{#11588}
2016-02-11 21:36:57 +00:00
kjellander
af71655b68 Revert of Android: Remove VideoCapturer (patchset #2 id:20001 of https://codereview.webrtc.org/1684403002/ )
Reason for revert:
Breaks downstream compilation. Please reland in a non-breaking fashion.

Original issue's description:
> Android: Remove VideoCapturer
>
> This CL makes PeerConnectionFactory.createVideoSource() and nativeCreateVideoSource work directly with VideoCapturerAndroid instead of going via VideoCapturer. The native part is now created in nativeCreateVideoSource() instead of doing it immediately in VideoCapturerAndroid.create().
>
> BUG=webrtc:5519
> R=perkj@webrtc.org
>
> Committed: https://crrev.com/09eab315fddc3432c19d8f662f4b9360f2a58010
> Cr-Commit-Position: refs/heads/master@{#11582}

TBR=perkj@webrtc.org,magjed@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=webrtc:5519

Review URL: https://codereview.webrtc.org/1690073002

Cr-Commit-Position: refs/heads/master@{#11586}
2016-02-11 20:21:48 +00:00
deadbeef
6ecee07bab Fixing bug in MediaStream.java that caused double disposal of track.
Also fixing an issue with the Java PeerConnection unit test.
It wasn't correctly waiting for 10 video frames to be received.

And fixed an issue with the video engine, where generated
black frames don't get any rotation.

BUG=webrtc:5128

Review URL: https://codereview.webrtc.org/1639583003

Cr-Commit-Position: refs/heads/master@{#11583}
2016-02-11 17:57:29 +00:00
Magnus Jedvert
09eab315fd Android: Remove VideoCapturer
This CL makes PeerConnectionFactory.createVideoSource() and nativeCreateVideoSource work directly with VideoCapturerAndroid instead of going via VideoCapturer. The native part is now created in nativeCreateVideoSource() instead of doing it immediately in VideoCapturerAndroid.create().

BUG=webrtc:5519
R=perkj@webrtc.org

Review URL: https://codereview.webrtc.org/1684403002 .

Cr-Commit-Position: refs/heads/master@{#11582}
2016-02-11 17:25:18 +00:00
perkj
162c3393be Revert of Make cricket::VideoCapturer implement VideoSourceInterface (patchset #14 id:300001 of https://codereview.webrtc.org/1655793003/ )
Reason for revert:
Needs to revert again unfortunately.
There are multiple implementations in Chrome of cricket::VideoCapturer.

One is ./../remoting/protocol/webrtc_video_capturer_adapter.cc...

https://build.chromium.org/p/chromium.webrtc.fyi/builders/Mac%20Builder/builds/9581/steps/compile/logs/stdio

Fun times - I will have to modify this cl after trying it manually out in Chrome.

Original issue's description:
> This cl introduce a VideoSourceInterface and let cricket::VideoCapturer implement it.
> Further more, it adds a VideoBroadcaster than is used for delivering frames to multiple sinks.
>
> BUG=webrtc:5426
> R=nisse@webrtc.org, pthatcher@webrtc.org
>
> Committed: https://crrev.com/4d19c5b010473615fa181afa84c6f4b3104e3171
> Cr-Commit-Position: refs/heads/master@{#11567}

TBR=pthatcher@google.com,nisse@webrtc.org,pthatcher@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=webrtc:5426

Review URL: https://codereview.webrtc.org/1690893002

Cr-Commit-Position: refs/heads/master@{#11568}
2016-02-11 10:56:41 +00:00
Per
4d19c5b010 This cl introduce a VideoSourceInterface and let cricket::VideoCapturer implement it.
Further more, it adds a VideoBroadcaster than is used for delivering frames to multiple sinks.

BUG=webrtc:5426
R=nisse@webrtc.org, pthatcher@webrtc.org

Review URL: https://codereview.webrtc.org/1655793003 .

Cr-Commit-Position: refs/heads/master@{#11567}
2016-02-11 10:06:19 +00:00
perkj
4b2a5a8095 Revert of Make cricket::VideoCapturer implement VideoSourceInterface (patchset #12 id:260001 of https://codereview.webrtc.org/1655793003/ )
Reason for revert:
Somehow breaks Chromium FYI....
https://build.chromium.org/p/chromium.webrtc.fyi/builders/Win%20Builder/builds/3483/steps/compile/logs/stdio

Original issue's description:
> This cl introduce a VideoSourceInterface and let cricket::VideoCapturer implement it.
> Further more, it adds a VideoBroadcaster than is used for delivering frames to multiple sinks.
>
>
> BUG=webrtc:5426

TBR=pthatcher@google.com,nisse@webrtc.org,pthatcher@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=webrtc:5426

Review URL: https://codereview.webrtc.org/1687273002

Cr-Commit-Position: refs/heads/master@{#11565}
2016-02-11 09:20:24 +00:00
perkj
2f21789b4b This cl introduce a VideoSourceInterface and let cricket::VideoCapturer implement it.
Further more, it adds a VideoBroadcaster than is used for delivering frames to multiple sinks.

BUG=webrtc:5426

Review URL: https://codereview.webrtc.org/1655793003

Cr-Commit-Position: refs/heads/master@{#11563}
2016-02-11 07:55:25 +00:00
kjellander
b24317bfda Fix license headers in webrtc/api.
In addition to the code moved from talk/app/webrtc
there were some files in webrtc/api/objctests that still
had the libjingle license header.

BUG=webrtc:5418
TBR=tkchin@webrtc.org
NOTRY=True

Review URL: https://codereview.webrtc.org/1680293005

Cr-Commit-Position: refs/heads/master@{#11552}
2016-02-10 15:54:53 +00:00
Henrik Kjellander
15583c19d7 Move talk/app/webrtc to webrtc/api
The previously disabled warnings that were inherited from
talk/build/common.gypi are now replaced by target-specific disabling
of only the failing warnings. Additional disabling was needed since the stricter
compilation warnings that applies to code in webrtc/.

License headers will be updated in a follow-up CL.

Other modifications:
* Updated the header guards.
* Sorted the includes using chromium/src/tools/sort-headers.py
  except for these files:
  talk/app/webrtc/peerconnectionendtoend_unittest.cc
  talk/app/webrtc/java/jni/androidmediadecoder_jni.cc
  talk/app/webrtc/java/jni/androidmediaencoder_jni.cc
  webrtc/media/devices/win32devicemanager.cc

The HAVE_SCTP define was added for the peerconnection_unittests target
in api_tests.gyp.

I also checked that none of
SRTP_RELATIVE_PATH
HAVE_SRTP
HAVE_WEBRTC_VIDEO
HAVE_WEBRTC_VOICE
were used by the talk/app/webrtc code.

For Chromium, the following changes will need to be applied to the roll CL that updates the
DEPS for WebRTC and libjingle:
https://codereview.chromium.org/1615433002

BUG=webrtc:5418
NOPRESUBMIT=True
R=deadbeef@webrtc.org, pthatcher@webrtc.org, tommi@webrtc.org

Review URL: https://codereview.webrtc.org/1610243002 .

Cr-Commit-Position: refs/heads/master@{#11545}
2016-02-10 09:53:26 +00:00
kjellander
f6b5509229 Fix GYP and GN references that are invalid in Chromium builds.
There were a couple of GN and GYP references that were incorrect in Chromium builds:
- GN references between WebRTC targets must be using relative paths, not absolute.
- GYP references between WebRTC targets must be using the <(webrtc_root)v variable
  in order to be expanded to the correct path in a Chromium build.

NOTRY=True
TBR=hjon@webrtc.org, hbos@webrtc.org

Review URL: https://codereview.webrtc.org/1681493002

Cr-Commit-Position: refs/heads/master@{#11521}
2016-02-08 07:04:33 +00:00
kjellander
a96e2d77cb Move talk/media to webrtc/media
I removed the 'libjingle' target in talk/libjingle.gyp and replaced
all users of it with base/base.gyp:rtc_base. It seems the jsoncpp
and expat dependencies were not used by it's previous references.

The files in talk/media/testdata were uploaded to Google Storage and
added .sha1 files in resources/media instead of simply moving them.

The previously disabled warnings that were inherited from
talk/build/common.gypi are now replaced by target-specific disabling
of only the failing warnings. Additional disabling was needed since the stricter
compilation warnings that applies to code in webrtc/.

License headers will be updated in a follow-up CL in order to not
break Git history.

Other modifications:
* Updated the header guards.
* Sorted the includes using chromium/src/tools/sort-headers.py
  except for these files:
  talk/app/webrtc/peerconnectionendtoend_unittest.cc
  talk/app/webrtc/java/jni/androidmediadecoder_jni.cc
  talk/app/webrtc/java/jni/androidmediaencoder_jni.cc
  webrtc/media/devices/win32devicemanager.cc.
* Unused GYP reference to libjingle_tests_additional_deps was removed.
* Removed duplicated GYP entries of
  webrtc/base/testutils.cc
  webrtc/base/testutils.h

The HAVE_WEBRTC_VIDEO and HAVE_WEBRTC_VOICE defines were used by only talk/media,
so they were moved to the media.gyp.

I also checked that none of
EXPAT_RELATIVE_PATH,
FEATURE_ENABLE_VOICEMAIL,
GTEST_RELATIVE_PATH,
JSONCPP_RELATIVE_PATH,
LOGGING=1,
SRTP_RELATIVE_PATH,
FEATURE_ENABLE_SSL,
FEATURE_ENABLE_VOICEMAIL,
FEATURE_ENABLE_PSTN,
HAVE_SCTP,
HAVE_SRTP,
are used by the talk/media code.

For Chromium, the following changes will need to be applied to the roll CL that updates the
DEPS for WebRTC and libjingle: https://codereview.chromium.org/1604303002/

BUG=webrtc:5420
NOPRESUBMIT=True
TBR=tommi@webrtc.org

Review URL: https://codereview.webrtc.org/1587193006

Cr-Commit-Position: refs/heads/master@{#11495}
2016-02-05 07:52:35 +00:00
tkchin
ab8f82ffe0 Make ECDSA default for RTCPeerConnection
BUG=

Review URL: https://codereview.webrtc.org/1649533002

Cr-Commit-Position: refs/heads/master@{#11409}
2016-01-28 01:50:15 +00:00
hjon
da2183c86f Update API for Objective-C RTCDataChannelConfiguration.
BUG=

Review URL: https://codereview.webrtc.org/1616363005

Cr-Commit-Position: refs/heads/master@{#11405}
2016-01-27 21:42:35 +00:00
hjon
6d49a8ed17 Update API for Objective-C RTCConfiguration.
BUG=

Review URL: https://codereview.webrtc.org/1616303002

Cr-Commit-Position: refs/heads/master@{#11386}
2016-01-26 21:06:48 +00:00
hjon
e373dc20c4 Update API for Objective-C RTCDataChannel.
BUG=

Review URL: https://codereview.webrtc.org/1545393003

Cr-Commit-Position: refs/heads/master@{#11362}
2016-01-22 22:04:33 +00:00
Jon Hjelle
2bf9a5f11b Update API for Objective-C RTCMediaStream.
BUG=
R=tkchin@webrtc.org

Review URL: https://codereview.webrtc.org/1558733002 .

Patch from Jon Hjelle <hjon@andyet.net>.

Cr-Commit-Position: refs/heads/master@{#11351}
2016-01-22 00:14:23 +00:00
Jon Hjelle
ca91e38a3a Update API for Objective-C RTCAudioTrack and RTCVideoTrack.
BUG=
R=tkchin@webrtc.org

Review URL: https://codereview.webrtc.org/1553743003 .

Patch from Jon Hjelle <hjon@andyet.net>.

Cr-Commit-Position: refs/heads/master@{#11350}
2016-01-21 23:36:54 +00:00
Jon Hjelle
7ac8babbc6 Move RTCAVFoundationCapturer to webrtc/api/objc.
BUG=
R=tkchin@webrtc.org

Review URL: https://codereview.webrtc.org/1559753002 .

Patch from Jon Hjelle <hjon@andyet.net>.

Cr-Commit-Position: refs/heads/master@{#11348}
2016-01-21 19:45:04 +00:00
Jon Hjelle
891a446a92 Update/move RTCVideoRendererAdapter to webrtc/api/objc.
BUG=
R=tkchin@webrtc.org

Review URL: https://codereview.webrtc.org/1533323003 .

Patch from Jon Hjelle <hjon@andyet.net>.

Cr-Commit-Position: refs/heads/master@{#11347}
2016-01-21 19:42:10 +00:00
Jon Hjelle
da99da81c9 Update API for Objective-C RTCPeerConnectionFactory.
BUG=
R=jiayl@webrtc.org, tkchin@webrtc.org

Review URL: https://codereview.webrtc.org/1558473002 .

Patch from Jon Hjelle <hjon@andyet.net>.

Cr-Commit-Position: refs/heads/master@{#11326}
2016-01-20 21:40:35 +00:00
Jon Hjelle
065aacc249 Move RTCVideoSource to webrtc/api/objc.
BUG=
R=tkchin@webrtc.org

Review URL: https://codereview.webrtc.org/1546783002 .

Patch from Jon Hjelle <hjon@andyet.net>.

Cr-Commit-Position: refs/heads/master@{#11325}
2016-01-20 21:25:53 +00:00
Jon Hjelle
f6c318ebae Update API for Objective-C RTCMediaSource.
BUG=
R=tkchin@webrtc.org

Review URL: https://codereview.webrtc.org/1538263002 .

Patch from Jon Hjelle <hjon@andyet.net>.

Cr-Commit-Position: refs/heads/master@{#11210}
2016-01-11 22:39:05 +00:00
Jon Hjelle
e799badacc Move Objective-C video renderers to webrtc/api/objc.
BUG=
R=tkchin@webrtc.org

Review URL: https://codereview.webrtc.org/1542473003 .

Patch from Jon Hjelle <hjon@andyet.net>.

Cr-Commit-Position: refs/heads/master@{#11209}
2016-01-11 21:47:17 +00:00
Jon Hjelle
81028796bc Update API for Objective-C RTCMediaStreamTrack.
R=tkchin@webrtc.org

Review URL: https://codereview.webrtc.org/1527143002 .

Patch from Jon Hjelle <hjon@andyet.net>.

Cr-Commit-Position: refs/heads/master@{#11208}
2016-01-11 21:16:19 +00:00
Jon Hjelle
a2c353f815 Update API for Objective-C RTCStats.
BUG=
R=tkchin@webrtc.org

Review URL: https://codereview.webrtc.org/1540113002 .

Patch from Jon Hjelle <hjon@andyet.net>.

Cr-Commit-Position: refs/heads/master@{#11207}
2016-01-11 21:11:45 +00:00
Jon Hjelle
7823495698 Move RTCI420Frame to webrtc/api/objc/RTCVideoFrame with minor style changes.
BUG=
R=tkchin@webrtc.org

Review URL: https://codereview.webrtc.org/1533193003 .

Patch from Jon Hjelle <hjon@andyet.net>.

Cr-Commit-Position: refs/heads/master@{#11203}
2016-01-11 17:47:14 +00:00
hjon
6f5ca080b8 Update API for Objective-C RTCMediaConstraints.
BUG=

Review URL: https://codereview.webrtc.org/1543033003

Cr-Commit-Position: refs/heads/master@{#11172}
2016-01-07 17:29:37 +00:00
Jon Hjelle
67e83d6539 Update API for Objective-C RTCSessionDescription.
BUG=
R=tkchin@webrtc.org

Review URL: https://codereview.webrtc.org/1524303006 .

Patch from Jon Hjelle <hjon@andyet.net>.

Cr-Commit-Position: refs/heads/master@{#11157}
2016-01-06 20:05:32 +00:00
Jon Hjelle
29d5e570b5 Update API for Objective-C RTCIceCandidate.
BUG=
R=tkchin@webrtc.org

Review URL: https://codereview.webrtc.org/1517253005 .

Patch from Jon Hjelle <hjon@andyet.net>.

Cr-Commit-Position: refs/heads/master@{#11156}
2016-01-06 19:49:18 +00:00
hjon
aa32c3e537 Update API for Objective-C RTCIceServer
BUG=

Review URL: https://codereview.webrtc.org/1499653003

Cr-Commit-Position: refs/heads/master@{#11000}
2015-12-14 03:58:19 +00:00