150 Commits

Author SHA1 Message Date
sakal
85d7650ab6 Make PeerConnectionClient non-singleton.
Ownership of EglBase is moved to PeerConnectionClient.

BUG=webrtc:8135

Review-Url: https://codereview.webrtc.org/3007893002
Cr-Commit-Position: refs/heads/master@{#19634}
2017-08-31 15:03:46 +00:00
Diogo Real
05ea2b39e0 Deprecate IceServer constructors and update dependencies
Bug: webrtc:8176
Change-Id: I2ebc0edf1776c49c202a181d7597099e9242c0e7
Reviewed-on: https://chromium-review.googlesource.com/642710
Commit-Queue: Diogo Real <diogor@google.com>
Reviewed-by: Sami Kalliomäki <sakal@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#19621}
2017-08-31 07:40:55 +00:00
sakal
91073ae78f Add a field trial to produce VideoFrames in camera capturers.
The field trials enables producing new VideoFrames in camera classes.
This field trial should be enabled if VideoSinks are used.

BUG=webrtc:7749, webrtc:7760

Review-Url: https://codereview.webrtc.org/2984633002
Cr-Commit-Position: refs/heads/master@{#19467}
2017-08-23 15:50:23 +00:00
sakal
fcf97c3b75 Fix fullscreen scaling in AppRTCMobile.
The surface view renderer size was set to match parent so it couldn't
adjust based on the frame size. The size is now set to wrap_content
which allows the renderer to adjust. The root element of the call
activity is changed to FrameLayout to allow the renderer to center.

requestLayout is added to SurfaceView setScalingType so onMeasure gets
called again.

BUG=webrtc:7901

Review-Url: https://codereview.webrtc.org/2978173002
Cr-Commit-Position: refs/heads/master@{#19073}
2017-07-18 12:01:08 +00:00
Ingemar Ådahl
87b6ddb561 Suppress MissingPrefix using tools attribute
Suppressing lint errors using comments is an undocumented feature of the
linter, and suppressing using the tools:ignore attribute should be
preferred.

Suppressing using comments becomes a problem when using the manifest
merger introduced in
6ada47bc79
as it reformats the comments slightly:
  <!--suppress MissingPrefix -->
becomes
  <!-- supress MissingPrefix -->
which causes the linter to disregard the suppression.

Bug: 740657
Change-Id: I8e365744d089271c390254e7c958b24b81043766
Reviewed-on: https://chromium-review.googlesource.com/566860
Reviewed-by: Magnus Jedvert <magjed@webrtc.org>
Commit-Queue: Ingemar Ådahl <ingemara@opera.com>
Cr-Commit-Position: refs/heads/master@{#18971}
2017-07-11 13:41:35 +00:00
henrika
cb576c50ee Fixes build issue based on usage of Android O specific API
BUG=NONE
NOTRY=TRUE

Review-Url: https://codereview.webrtc.org/2967043002
Cr-Commit-Position: refs/heads/master@{#18893}
2017-07-04 14:02:35 +00:00
Gustavo Garcia
c43f68e52c Fix do not unregister bluetooth receiver if it was not registered
Bug: webrtc:7890
Change-Id: Ib46b4a4407fa030500930ed03a093b26c71f8963
Reviewed-on: https://chromium-review.googlesource.com/550617
Commit-Queue: Henrik Andreasson <henrika@webrtc.org>
Reviewed-by: Henrik Andreasson <henrika@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#18892}
2017-07-04 13:50:15 +00:00
henrika
8eadead3f4 Adds support for USB audio devices in AppRTCMobile on Android.
This change extends the definition of wired headset to also include USB
devices. The effect is that audio will now be routed to USB audio devices
when used in combination with AppRTCMobile.

BUG=webrtc:7931

Review-Url: https://codereview.webrtc.org/2971613003
Cr-Commit-Position: refs/heads/master@{#18889}
2017-07-04 12:10:48 +00:00
henrika
49085ef280 Improves audio-routing in combination with BT in AppRTCMobile on Android.
This CL improves (speeds up) audio routing for BT devices in AppRTCMobile.

NOTRY=TRUE
BUG=webrtc:7888

Review-Url: https://codereview.webrtc.org/2961403003
Cr-Commit-Position: refs/heads/master@{#18858}
2017-06-30 13:25:25 +00:00
Sami Kalliomäki
2a8856cc4a Switch from ScheduledExecutorService to ExecutorService.
ScheduledExecutorService silently ignores exceptions thrown by the
runnable. This makes debugging issues unnecessarily difficult.

Bug: None
Change-Id: I7deb43b96e5639c096b9aed9c6ff9b197b62f59f
Reviewed-on: https://chromium-review.googlesource.com/521084
Reviewed-by: Magnus Jedvert <magjed@webrtc.org>
Commit-Queue: Sami Kalliomäki <sakal@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#18378}
2017-06-01 12:05:53 +00:00
peah
b274204feb AppRTCMobile support to turn off the WebRTC AGC and HPF
This CL adds support for turning off the WebRTC AGC
and HPF in AppRTCMobile.

BUG=webrtc:6183,webrtc:6220

Review-Url: https://codereview.webrtc.org/2871393002
Cr-Commit-Position: refs/heads/master@{#18204}
2017-05-18 22:09:33 +00:00
oprypin
054be4c9d9 Support running AppRTC without a TURN ICE server
The "ice_server_url" key is always present in AppRTC server's JSON response but may be empty if no ICE server is wanted.

BUG=webrtc:7636

Review-Url: https://codereview.webrtc.org/2878673002
Cr-Commit-Position: refs/heads/master@{#18118}
2017-05-12 07:40:58 +00:00
glaznev
49c8f26ad1 Initial implementation of Android audio playback error handling.
BUG=b/34128648

Review-Url: https://codereview.webrtc.org/2861573002
Cr-Commit-Position: refs/heads/master@{#18002}
2017-05-03 18:32:39 +00:00
sakal
44116a5dc5 Fix lint issues on Android.
BUG=webrtc:7549

Review-Url: https://codereview.webrtc.org/2853283002
Cr-Commit-Position: refs/heads/master@{#17982}
2017-05-03 10:19:08 +00:00
oprypin
9c7e56498b Properly send URL parameters in all requests
https://codereview.webrtc.org/2825313002/
added this only to connection URL but it's needed everywhere

BUG=webrtc:7548

Review-Url: https://codereview.webrtc.org/2858493003
Cr-Commit-Position: refs/heads/master@{#17981}
2017-05-03 08:58:39 +00:00
sakal
bee4ff8d82 Remove unnecessary runtime API-level checks.
APIs below level 16 are not supported by WebRTC.

BUG=webrtc:7549
TBR=henrika@webrtc.org

Review-Url: https://codereview.webrtc.org/2848323003
Cr-Commit-Position: refs/heads/master@{#17980}
2017-05-02 15:33:52 +00:00
brandtr
56c78aea5f Update FlexFEC field trial string in AppRTCMobile Android.
BUG=webrtc:5654

Review-Url: https://codereview.webrtc.org/2847543004
Cr-Commit-Position: refs/heads/master@{#17924}
2017-04-28 09:52:20 +00:00
oprypin
30cda5ef98 Espresso test for loopback video quality testing
Update the AppRTCMobileTestStubbedVideoIO test to run on
phones without Internet connection. This is done by bringing up
a local instance of AppRTC on the Linux machine connected to
the Android device.

Running this test will need the webrtc.DEPS solution to be configured
for the checkout, since that will pull down the precompiled AppRTC
package that is needed.

Continued from http://crrev.com/2780493002#ps20001 (by kjellander@)
Continued from http://crrev.com/2741743002#ps180001 (by mandermo@)

BUG=webrtc:7185

Review-Url: https://codereview.webrtc.org/2825313002
Cr-Commit-Position: refs/heads/master@{#17838}
2017-04-24 11:15:13 +00:00
glaznev
07cd1ba023 Add error codes for Android audio recording start errors.
BUG=b/36090624

Review-Url: https://codereview.webrtc.org/2808273002
Cr-Commit-Position: refs/heads/master@{#17747}
2017-04-18 17:30:29 +00:00
deadbeef
b4fc73a3ab Removing unnecessary parameters from initializeAndroidGlobals.
The "initialize audio/video" parameters are no longer needed, but
at the same time were required to be true, causing a lot of confusion.
This CL removes them, but leaves the old method signature around,
marked "deprecated".

BUG=webrtc:3416
TBR=solenberg@webrtc.org

Review-Url: https://codereview.webrtc.org/2800353002
Cr-Commit-Position: refs/heads/master@{#17626}
2017-04-10 22:08:02 +00:00
kjellander
c898825eb4 Add kjellander to OWNERS for *.py in examples/android{app,tests}
BUG=webrtc:7229
NOTRY=True

Review-Url: https://codereview.webrtc.org/2735673002
Cr-Commit-Position: refs/heads/master@{#17062}
2017-03-06 11:56:57 +00:00
deadbeef
f0a539b0c8 Revert of Add the url attribute to the IceCandidate (Java Wrapper) (patchset #4 id:120001 of https://codereview.webrtc.org/2690593002/ )
Reason for revert:
Breaks AppRTCMobile interoperability. The ICE candidate URL shouldn't be signaled between endpoints, it's only there for informational purposes.

Original issue's description:
> Add the url attribute to the IceCandidate (Java Wrapper)
>
> The url of the ICE server is added to the IceCandiate class.
> This can be used to tell which server this candidate was gathered from.
>
> BUG=webrtc:7128
>
> Review-Url: https://codereview.webrtc.org/2690593002
> Cr-Original-Commit-Position: refs/heads/master@{#16593}
> Committed: 8586c8ee88
> Review-Url: https://codereview.webrtc.org/2690593002
> Cr-Commit-Position: refs/heads/master@{#16615}
> Committed: 45efce01c7

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

Review-Url: https://codereview.webrtc.org/2699533002
Cr-Commit-Position: refs/heads/master@{#16616}
2017-02-14 22:13:56 +00:00
zhihuang
45efce01c7 Add the url attribute to the IceCandidate (Java Wrapper)
The url of the ICE server is added to the IceCandiate class.
This can be used to tell which server this candidate was gathered from.

BUG=webrtc:7128

Review-Url: https://codereview.webrtc.org/2690593002
Cr-Original-Commit-Position: refs/heads/master@{#16593}
Committed: 8586c8ee88
Review-Url: https://codereview.webrtc.org/2690593002
Cr-Commit-Position: refs/heads/master@{#16615}
2017-02-14 20:23:34 +00:00
Magnus Jedvert
0706813280 Android AppRTCMobile: Add setting for selecting H264 Baseline or High profile
BUG=webrtc:6337
R=glaznev@webrtc.org

Review-Url: https://codereview.webrtc.org/2658243002 .
Cr-Commit-Position: refs/heads/master@{#16605}
2017-02-14 11:41:35 +00:00
deadbeef
b856794be7 Revert of Add the url attribute to the IceCandidate (Java Wrapper) (patchset #3 id:60001 of https://codereview.webrtc.org/2690593002/ )
Reason for revert:
Breaks downstream application's build

Original issue's description:
> Add the url attribute to the IceCandidate (Java Wrapper)
>
> The url of the ICE server is added to the IceCandiate class.
> This can be used to tell which server this candidate was gathered from.
>
> BUG=webrtc:7128
>
> Review-Url: https://codereview.webrtc.org/2690593002
> Cr-Commit-Position: refs/heads/master@{#16593}
> Committed: 8586c8ee88

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

Review-Url: https://codereview.webrtc.org/2692993002
Cr-Commit-Position: refs/heads/master@{#16595}
2017-02-13 22:31:38 +00:00
zhihuang
8586c8ee88 Add the url attribute to the IceCandidate (Java Wrapper)
The url of the ICE server is added to the IceCandiate class.
This can be used to tell which server this candidate was gathered from.

BUG=webrtc:7128

Review-Url: https://codereview.webrtc.org/2690593002
Cr-Commit-Position: refs/heads/master@{#16593}
2017-02-13 22:04:50 +00:00
sakal
07a050f995 Add support for swapping feeds in Android AppRTCMobile.
BUG=webrtc:6937

Review-Url: https://codereview.webrtc.org/2682943006
Cr-Commit-Position: refs/heads/master@{#16582}
2017-02-13 13:58:27 +00:00
sakal
cb789bb510 Remove NewApi lint suppression.
BUG=webrtc:6597

Review-Url: https://codereview.webrtc.org/2662273004
Cr-Commit-Position: refs/heads/master@{#16448}
2017-02-06 13:34:26 +00:00
henrika
447dba9586 Add debuggable=true to AppRTCMobile manifest.
Improves possibility to debug the demo application using adb.
As an example, now allows 'adb run as' which is useful when profiling CPU. It enables us to do profiling on non-rooted devices (excluding details).

BUG=NONE

Review-Url: https://codereview.webrtc.org/2676983003
Cr-Commit-Position: refs/heads/master@{#16446}
2017-02-06 12:58:01 +00:00
sakal
f7826d668a Remove InlinedApi lint ignore.
Adds ignore for all lint errors in Chromium code. Changes minimum SDK for
instrumentation tests to 16 from 14. Adds TargetApi annotations.

BUG=webrtc:6597

Review-Url: https://codereview.webrtc.org/2670473004
Cr-Commit-Position: refs/heads/master@{#16412}
2017-02-02 08:53:33 +00:00
magjed
93f01be4fd Android AppRTCMobile: Fix SDP video codec reordering for multiple H264 profiles
Since we can now have multiple H264 payload type, we need to move all of them to the beginning of the codec list, instead of greedily taking the first payload type that matches the preferred codec name.

BUG=webrtc:6738

Review-Url: https://codereview.webrtc.org/2658573009
Cr-Commit-Position: refs/heads/master@{#16349}
2017-01-29 23:14:17 +00:00
glaznev
0c1d060b24 Enable Android H264 High profile decoder
Based on Magnus's
https://codereview.webrtc.org/2646423002/

BUG=webrtc:6337

Review-Url: https://codereview.webrtc.org/2654003005
Cr-Commit-Position: refs/heads/master@{#16332}
2017-01-27 20:24:24 +00:00
aleloi
011240333e Minor style change suggested by internal static analysis tool.
TBR=sakal@webrtc.org
BUG=None

Review-Url: https://codereview.webrtc.org/2646413002
Cr-Commit-Position: refs/heads/master@{#16207}
2017-01-23 11:10:39 +00:00
sakal
0b56279da1 Catch failure to load native dependencies.
BUG=webrtc:6751

Review-Url: https://codereview.webrtc.org/2652623002
Cr-Commit-Position: refs/heads/master@{#16205}
2017-01-23 11:02:56 +00:00
sakal
c854ac3755 Stop camera onStop instead of onPause.
In multi-window mode the non-active activity receives onPause. We
shouldn't stop the camera in this case.

BUG=webrtc:7018

Review-Url: https://codereview.webrtc.org/2648483003
Cr-Commit-Position: refs/heads/master@{#16186}
2017-01-20 12:09:11 +00:00
sakal
30fe5e0d10 Prevent downstream linter warnings.
BUG=None

Review-Url: https://codereview.webrtc.org/2643853007
Cr-Commit-Position: refs/heads/master@{#16183}
2017-01-20 11:10:08 +00:00
sakal
fd6c94d311 Allow more config changes for CallActivity.
CallActivity doesn't survive recreation so we have to handle these config
changes. Fortunately, they don't seem to require any special handling.

BUG=webrtc:7018

Review-Url: https://codereview.webrtc.org/2645853002
Cr-Commit-Position: refs/heads/master@{#16180}
2017-01-20 10:36:49 +00:00
sakal
3e9229045e Load library dependencies in AppRTCMobile.
Older Android versions have trouble locating the library dependencies
automatically. Loading them manually resolves the issue.

BUG=webrtc:6751

Review-Url: https://codereview.webrtc.org/2635233002
Cr-Commit-Position: refs/heads/master@{#16179}
2017-01-20 09:46:50 +00:00
sakal
e5cbc20190 Android: AppRTCMobile: Don't leak CallActivity.
Previously CallActivity would be leaked on every call. This CL fixes the
problem.

BUG=webrtc:6684

Review-Url: https://codereview.webrtc.org/2640433003
Cr-Commit-Position: refs/heads/master@{#16123}
2017-01-17 15:25:53 +00:00
mandermo
a6069e8a01 Espresso test case to control loopback call
The test case is put inside a new test target. That test target will be started from a test script to asses video quality.

BUG=webrtc:6545

Review-Url: https://codereview.webrtc.org/2585813002
Cr-Commit-Position: refs/heads/master@{#16088}
2017-01-16 10:23:09 +00:00
sakal
bca122e0d5 Remove lint ignores and add WrongCall ignore directly to the test.
Also removes some unused strings from AppRTCMobile strings.xml.

BUG=webrtc:6597
TBR=kjellander@webrtc.org

Review-Url: https://codereview.webrtc.org/2628833004
Cr-Commit-Position: refs/heads/master@{#16033}
2017-01-12 14:19:40 +00:00
magjed
295760daa1 Reland of Android: Add field trial for Intel HW Vp8 encoder (patchset #1 id:1 of https://codereview.webrtc.org/2624143002/ )
Reason for revert:
Fixed external test issues.

Original issue's description:
> Revert of Android: Add field trial for Intel HW Vp8 encoder (patchset #1 id:1 of https://codereview.webrtc.org/2614373004/ )
>
> Reason for revert:
> Breaks external test code.
>
> Original issue's description:
> > Android: Add field trial for Intel HW Vp8 encoder
> >
> > Also enable Intel HW Vp8 encoder by default in AppRTCMobile.
> >
> > BUG=webrtc:6683
> >
> > Review-Url: https://codereview.webrtc.org/2614373004
> > Cr-Commit-Position: refs/heads/master@{#16002}
> > Committed: cecf86e9b0
>
> TBR=sakal@webrtc.org
> # Skipping CQ checks because original CL landed less than 1 days ago.
> NOPRESUBMIT=true
> NOTREECHECKS=true
> NOTRY=true
> BUG=webrtc:6683
>
> Review-Url: https://codereview.webrtc.org/2624143002
> Cr-Commit-Position: refs/heads/master@{#16005}
> Committed: c999a08128

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

Review-Url: https://codereview.webrtc.org/2625903005
Cr-Commit-Position: refs/heads/master@{#16025}
2017-01-12 09:11:57 +00:00
Alex Glaznev
1a9e2108e3 Initial implementation of Android audio recording error handling.
BUG=b/34128648
R=henrika@webrtc.org

Review-Url: https://codereview.webrtc.org/2620453004 .
Cr-Commit-Position: refs/heads/master@{#16017}
2017-01-11 21:00:01 +00:00
magjed
c999a08128 Revert of Android: Add field trial for Intel HW Vp8 encoder (patchset #1 id:1 of https://codereview.webrtc.org/2614373004/ )
Reason for revert:
Breaks external test code.

Original issue's description:
> Android: Add field trial for Intel HW Vp8 encoder
>
> Also enable Intel HW Vp8 encoder by default in AppRTCMobile.
>
> BUG=webrtc:6683
>
> Review-Url: https://codereview.webrtc.org/2614373004
> Cr-Commit-Position: refs/heads/master@{#16002}
> Committed: cecf86e9b0

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

Review-Url: https://codereview.webrtc.org/2624143002
Cr-Commit-Position: refs/heads/master@{#16005}
2017-01-11 11:02:13 +00:00
magjed
cecf86e9b0 Android: Add field trial for Intel HW Vp8 encoder
Also enable Intel HW Vp8 encoder by default in AppRTCMobile.

BUG=webrtc:6683

Review-Url: https://codereview.webrtc.org/2614373004
Cr-Commit-Position: refs/heads/master@{#16002}
2017-01-11 08:57:43 +00:00
zhihuang
dcccda7e7c Created a java wrapper for the callback OnAddTrack to PeerConnection.Observer
Created a java wrapper for the callback OnAddTrack in this CL since it has been added to native C++ API
The callback function is called when a track is signaled by remote side and a new RtpReceiver is created.
The application can tell when tracks are added to the streams by listening to this callback.

BUG=webrtc:6112

Review-Url: https://codereview.webrtc.org/2513723002
Cr-Commit-Position: refs/heads/master@{#15745}
2016-12-21 22:08:03 +00:00
henrika
c3c2f31852 Adds basic Bluetooth support to AppRTCMobile
BUG=webrtc:6649

- Supports Bluetooth Headset profile.
- Detects new BT headset:
  + enabled at start, and
  + powered on during active call.
- Enables/disables BT SCO channel when BT device is selected.
- Removes proximity sensor usage to avoid conflicts (will be added again later).
- Adds new (unused) APIs to explicitly select audio device.
- Starts routing audio to BT headset when enabled, i.e, BT is default.

Review-Url: https://codereview.webrtc.org/2501983002
Cr-Commit-Position: refs/heads/master@{#15610}
2016-12-14 15:37:01 +00:00
brandtr
0582e6ca36 Add FlexFEC settings toggle in Android AppRTCMobile.
BUG=webrtc:5654

Review-Url: https://codereview.webrtc.org/2550393002
Cr-Commit-Position: refs/heads/master@{#15481}
2016-12-08 14:51:35 +00:00
sakal
b426040788 Add Full HD and 4K camera resolutions to AppRTCMobile Android.
BUG=webrtc:6745,webrtc:6734

Review-Url: https://codereview.webrtc.org/2520313002
Cr-Commit-Position: refs/heads/master@{#15192}
2016-11-22 14:21:44 +00:00
sakal
b1e6d5efa6 Set surface view surface size to minimum of the layout size and frame size.
This improves the performance of SurfaceViewRenderer. This feature is added
behind a flag for now because it can be buggy on some devices.

BUG=webrtc:6470

Review-Url: https://codereview.webrtc.org/2510413002
Cr-Commit-Position: refs/heads/master@{#15181}
2016-11-22 09:54:47 +00:00