216 Commits

Author SHA1 Message Date
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
sakal
b621c3f5e4 Move Android tests under sdk/android.
BUG=None

Review-Url: https://codereview.webrtc.org/2657813003
Cr-Commit-Position: refs/heads/master@{#16323}
2017-01-27 13:14:59 +00:00
kthelgason
d3adbfb13c AppRTCMobile links against framework target.
BUG=None

Review-Url: https://codereview.webrtc.org/2656833002
Cr-Commit-Position: refs/heads/master@{#16287}
2017-01-26 09:14:04 +00:00
haysc
148e370526 iOS: Add SendSideBweWithOverhead field trial key
BUG=0

Review-Url: https://codereview.webrtc.org/2649923011
Cr-Commit-Position: refs/heads/master@{#16275}
2017-01-25 18:02:20 +00:00
nisse
7d2542623a Delete unneeded includes of base/common.h.
Bulk of the changes were done using

   git grep -l '#include "webrtc/base/common.h"' | \
     xargs sed -i '\,^#include.*webrtc/base/common\.h,d'

followed by adding back the include in the few places where it is
still needed, and in one case (pseudotcp.cc) instead deleting its use
of RTC_UNUSED.

BUG=webrtc:6424

Review-Url: https://codereview.webrtc.org/2644103002
Cr-Commit-Position: refs/heads/master@{#16263}
2017-01-25 09:47:24 +00:00
mbonadei
9aa3f0a200 Reland of Moving webrtc.gni up one level from build/ (patchset #1 id:1 of https://codereview.webrtc.org/2657563002/ )
Reason for revert:
Starting to work on a fix (it seems that there are third_party dependencies that depends on the path to the webrtc.gni file)

Original issue's description:
> Revert of Moving webrtc.gni up one level from build/ (patchset #1 id:1 of https://codereview.webrtc.org/2651543003/ )
>
> Reason for revert:
> This was causing the following failure: https://build.chromium.org/p/chromium.webrtc.fyi/builders/Android%20Builder/builds/838/steps/generate_build_files/logs/stdio
>
> Original issue's description:
> > Moving webrtc.gni up one level from build/
> >
> > BUG=webrtc:7030
> >
> > Review-Url: https://codereview.webrtc.org/2651543003
> > Cr-Commit-Position: refs/heads/master@{#16241}
> > Committed: 35a32700fc
>
> TBR=kjellander@webrtc.org
> # Skipping CQ checks because original CL landed less than 1 days ago.
> NOPRESUBMIT=true
> NOTREECHECKS=true
> NOTRY=true
> BUG=webrtc:7030
>
> Review-Url: https://codereview.webrtc.org/2657563002
> Cr-Commit-Position: refs/heads/master@{#16244}
> Committed: 69dc7dbe24

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

Review-Url: https://codereview.webrtc.org/2654773002
Cr-Commit-Position: refs/heads/master@{#16247}
2017-01-24 14:58:22 +00:00
mbonadei
69dc7dbe24 Revert of Moving webrtc.gni up one level from build/ (patchset #1 id:1 of https://codereview.webrtc.org/2651543003/ )
Reason for revert:
This was causing the following failure: https://build.chromium.org/p/chromium.webrtc.fyi/builders/Android%20Builder/builds/838/steps/generate_build_files/logs/stdio

Original issue's description:
> Moving webrtc.gni up one level from build/
>
> BUG=webrtc:7030
>
> Review-Url: https://codereview.webrtc.org/2651543003
> Cr-Commit-Position: refs/heads/master@{#16241}
> Committed: 35a32700fc

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

Review-Url: https://codereview.webrtc.org/2657563002
Cr-Commit-Position: refs/heads/master@{#16244}
2017-01-24 13:14:35 +00:00
mbonadei
35a32700fc Moving webrtc.gni up one level from build/
BUG=webrtc:7030

Review-Url: https://codereview.webrtc.org/2651543003
Cr-Commit-Position: refs/heads/master@{#16241}
2017-01-24 12:49:35 +00:00
sakal
a4a753857e Android: Script for building libwebrtc.aar.
BUG=webrtc:7023

Review-Url: https://codereview.webrtc.org/2653533004
Cr-Commit-Position: refs/heads/master@{#16232}
2017-01-24 09:25:50 +00:00
tkchin
4c78702d12 iOS: Add MedianSlopeFilter field trial.
BUG=0

Review-Url: https://codereview.webrtc.org/2646443013
Cr-Commit-Position: refs/heads/master@{#16223}
2017-01-23 19:24:57 +00:00
aleloi
a067013e90 Minor style change suggested by internal static analysis tool.
BUG=None

Review-Url: https://codereview.webrtc.org/2645333003
Cr-Commit-Position: refs/heads/master@{#16211}
2017-01-23 14:09:35 +00:00
ossu
7bb87ee4e8 Create //webrtc/api:libjingle_peerconnection_api + refactorings.
Create a new target //webrtc/api:libjingle_peerconnection_api and start moving
things into it. Move remaining parts of //webrtc/api:libjingle_peerconnection
to //webrtc/pc:libjingle_peerconnection.

Moved the RTCStatsCollectorCallback into its own header file, so that
PeerConnectionInterface can include that instead of pulling in
RTCStatsCollector and PeerConnection and everything.

Separated cricket::MediaType into its own header/source set, so that it
can be used in the api.

BUG=webrtc:5883

Review-Url: https://codereview.webrtc.org/2514883002
Cr-Commit-Position: refs/heads/master@{#16210}
2017-01-23 12:56:25 +00:00
mbonadei
b55bd97972 Reland of Creating libwebrtc bundle jar (patchset #1 id:1 of https://codereview.webrtc.org/2640023010/ )
Reason for revert:
It seems that we cannot skip the generation of "//webrtc/base/base_java" in chromium without some refactoring because it is included as a dependency in some places.

Original issue's description:
> Revert of Creating libwebrtc bundle jar (patchset #4 id:60001 of https://codereview.webrtc.org/2646443002/ )
>
> Reason for revert:
> This breaks some chromium.webrtc.fyi buildbots with the following error:
>
> ERROR Unresolved dependencies.
> //third_party/webrtc/base:base(//build/toolchain/android:android_arm)
>   needs //third_party/webrtc/base:base_java(//build/toolchain/android:android_arm)
>
>
> Original issue's description:
> > Creating libwebrtc bundle jar
> >
> > Creates a JAR which includes:
> > - //webrtc/base:base_java
> > - //webrtc/modules/audio_device:audio_device_java
> > - //webrtc/sdk/android:libjingle_peerconnection_java
> > - //webrtc/sdk/android:libjingle_peerconnection_metrics_default_java
> >
> > The libwebrtc.jar file will be generated at '<output_dir>/lib.java/webrtc/sdk/android/libwebrtc.jar'.
> >
> > BUG=webrtc:6356
> >
> > Review-Url: https://codereview.webrtc.org/2646443002
> > Cr-Commit-Position: refs/heads/master@{#16189}
> > Committed: a62a82b7e7
>
> TBR=kjellander@webrtc.org,sakal@webrtc.org
> # Skipping CQ checks because original CL landed less than 1 days ago.
> NOPRESUBMIT=true
> NOTREECHECKS=true
> NOTRY=true
> BUG=webrtc:6356
>
> Review-Url: https://codereview.webrtc.org/2640023010
> Cr-Commit-Position: refs/heads/master@{#16190}
> Committed: 3c9151b953

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

Review-Url: https://codereview.webrtc.org/2646093004
Cr-Commit-Position: refs/heads/master@{#16203}
2017-01-23 09:25:53 +00:00
magjed
aea1a017ed Move webrtc/sdk/DEPS to webrtc/sdk/objc/DEPS
The folder webrtc/sdk/ now contains android as well, so we should move the objc DEPS file to the objc folder.

TBR=tommi
BUG=None

Review-Url: https://codereview.webrtc.org/2644733008
Cr-Commit-Position: refs/heads/master@{#16191}
2017-01-20 14:56:44 +00:00
mbonadei
3c9151b953 Revert of Creating libwebrtc bundle jar (patchset #4 id:60001 of https://codereview.webrtc.org/2646443002/ )
Reason for revert:
This breaks some chromium.webrtc.fyi buildbots with the following error:

ERROR Unresolved dependencies.
//third_party/webrtc/base:base(//build/toolchain/android:android_arm)
  needs //third_party/webrtc/base:base_java(//build/toolchain/android:android_arm)

Original issue's description:
> Creating libwebrtc bundle jar
>
> Creates a JAR which includes:
> - //webrtc/base:base_java
> - //webrtc/modules/audio_device:audio_device_java
> - //webrtc/sdk/android:libjingle_peerconnection_java
> - //webrtc/sdk/android:libjingle_peerconnection_metrics_default_java
>
> The libwebrtc.jar file will be generated at '<output_dir>/lib.java/webrtc/sdk/android/libwebrtc.jar'.
>
> BUG=webrtc:6356
>
> Review-Url: https://codereview.webrtc.org/2646443002
> Cr-Commit-Position: refs/heads/master@{#16189}
> Committed: a62a82b7e7

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

Review-Url: https://codereview.webrtc.org/2640023010
Cr-Commit-Position: refs/heads/master@{#16190}
2017-01-20 14:48:03 +00:00
mbonadei
a62a82b7e7 Creating libwebrtc bundle jar
Creates a JAR which includes:
- //webrtc/base:base_java
- //webrtc/modules/audio_device:audio_device_java
- //webrtc/sdk/android:libjingle_peerconnection_java
- //webrtc/sdk/android:libjingle_peerconnection_metrics_default_java

The libwebrtc.jar file will be generated at '<output_dir>/lib.java/webrtc/sdk/android/libwebrtc.jar'.

BUG=webrtc:6356

Review-Url: https://codereview.webrtc.org/2646443002
Cr-Commit-Position: refs/heads/master@{#16189}
2017-01-20 14:15:34 +00:00
sakal
35564065ca Camera1Session: Fix camera sometimes getting stopped twice.
Moves setting state as stopped to stopInternal. Checks that state is not
stopped in stopInternal.

BUG=webrtc:7015

Review-Url: https://codereview.webrtc.org/2640093003
Cr-Commit-Position: refs/heads/master@{#16182}
2017-01-20 11:09:03 +00:00
mandermo
eef94d9995 Video collected by VideoFileRenderer is first saved on the native heap, then saved to disk during release.
BUG=webrtc:6545

Review-Url: https://codereview.webrtc.org/2576283004
Cr-Commit-Position: refs/heads/master@{#16167}
2017-01-19 17:02:29 +00:00
nisse
e8abe3ef1b Revert of New method StatsObserver::OnCompleteReports, passing ownership. (patchset #2 id:20001 of https://codereview.webrtc.org/2584553002/ )
Reason for revert:
The new method doesn't work as intended.

It can't pass ownership, because the StatsReports is a vector of raw pointers to StatReport objects owned by the StatsCollector.

Original issue's description:
> New method StatsObserver::OnCompleteReports, passing ownership.
>
> The new name, OnCompleteReports rather than OnComplete, is needed
> because in C++ method lookup, overriding a method hides all otherwise
> inherited methods with the same name, even if they have a different
> signature. And here, the intention is that each subclass should
> override one or the other of the two methods, and inherit the method it
> doesn't override.
>
> This cl is a prerequisite for
> https://codereview.webrtc.org/2567143003/, because the Chrome glue
> code needs to retain the stats report after the OnComplete method has
> returned.
>
> Currently, Chrome makes a copy of the stats mapping (which breaks when
> changing ValuePtr from an rtc::linked_ptr to an std::unique_ptr). After
> this cl, Chrome can be fixed to take ownership and no longer needs to
> copy anything, unblocking cl 2567143003.
>
> BUG=webrtc:6424
>
> Review-Url: https://codereview.webrtc.org/2584553002
> Cr-Commit-Position: refs/heads/master@{#15708}
> Committed: b36ee8d498

TBR=solenberg@webrtc.org,magjed@webrtc.org,tkchin@webrtc.org,hbos@webrtc.org
# Not skipping CQ checks because original CL landed more than 1 days ago.
BUG=webrtc:6424

Review-Url: https://codereview.webrtc.org/2641783002
Cr-Commit-Position: refs/heads/master@{#16144}
2017-01-18 13:00:34 +00:00
sakal
5850a9484d Add failure type parameter to onFailure callback.
This allows Camera2Session to correctly signal camera disconnect
when starting the camera.

BUG=webrtc:7008

Review-Url: https://codereview.webrtc.org/2642703002
Cr-Commit-Position: refs/heads/master@{#16142}
2017-01-18 11:22:16 +00:00
sakal
2fcd2dd93a Update YuvConverter to use GlTextureFrameBuffer.
Old implementation also had a bug where it had the framebuffer bound
while changing the texture size. This causes problems on some phones.

BUG=webrtc:6751

Review-Url: https://codereview.webrtc.org/2635133003
Cr-Commit-Position: refs/heads/master@{#16141}
2017-01-18 11:21:10 +00:00
Alex Glaznev
7fa4a72924 Increase bitrate adjustment values for VP8 Exynos encoder
For low bitrates actual encoder output bitrate may differ from target
by 3-4 times.
Also adjust adaptation speed based on bitrate variation from the target.

BUG=b/34233384
R=wzh@webrtc.org

Review-Url: https://codereview.webrtc.org/2640543003 .
Cr-Commit-Position: refs/heads/master@{#16128}
2017-01-17 23:32:02 +00:00
sakal
e8aca24446 Move file capturer/renderer tests to the correct location.
Move file capturer/renderer tests from the AppRTCMobile tests directory
to the WebRTC tests directory. These tests do not test AppRTCMobile but
rather WebRTC functionality. Therefore, they belong in WebRTC tests
directory.

BUG=webrtc:6545

Review-Url: https://codereview.webrtc.org/2632233002
Cr-Commit-Position: refs/heads/master@{#16115}
2017-01-17 11:32:06 +00:00
magjed
9b96a172ed Android GlTextureFrameBuffer: Re-attach texture in setSize
BUG=None

Review-Url: https://codereview.webrtc.org/2571503002
Cr-Commit-Position: refs/heads/master@{#16110}
2017-01-17 10:51:06 +00:00
hankzhang8945
9506e12eba Reset pendingCameraSwitch as false after failed to post switchCameraOnThread to camera thread.
BUG=webrtc:6981

Review-Url: https://codereview.webrtc.org/2625133007
Cr-Commit-Position: refs/heads/master@{#16105}
2017-01-17 09:29:19 +00:00
sakal
c117e2ed79 Do not classify error after stopping the camera as a startup failure.
Calling event handlers when the camera is closing is safe because
CameraCapturer checks if the errors are coming from the current session.

Calling onFailure after camera has already started might lead to strange
behavior.

BUG=b/34112992

Review-Url: https://codereview.webrtc.org/2634973002
Cr-Commit-Position: refs/heads/master@{#16101}
2017-01-16 17:40:36 +00:00
sakal
037b93af17 Replace default locale with US locale on Android.
This fixes a lint warning and also fixes potential bugs on devices
running locales where toLowerCase and toUpperCase don't behave
as expected.

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

Review-Url: https://codereview.webrtc.org/2624423003
Cr-Commit-Position: refs/heads/master@{#16092}
2017-01-16 12:57:32 +00:00
deadbeef
fe0fd41bb9 Stop using deprecated constraints-based version of CreateAudioSource.
Also did some slight refactoring of the code that turns constraints
into rtc::Optionals. Used a template method to avoid code duplication,
and used the same pattern for "CopyConstraintsIntoAudioOptions" as was
being used for "CopyConstraintsIntoRtcConfiguration".

BUG=webrtc:6752

Review-Url: https://codereview.webrtc.org/2628523003
Cr-Commit-Position: refs/heads/master@{#16063}
2017-01-13 19:47:56 +00:00
magjed
bf0845201a Remove use of PCH files in webrtc/sdk/objc
A decision has been made to not use prefix header files.

BUG=None

Review-Url: https://codereview.webrtc.org/2590823002
Cr-Commit-Position: refs/heads/master@{#16056}
2017-01-13 15:10:16 +00:00
sakal
c5da08fc12 Drop dependency to Chromium in WebRtcJniBootTest.
The dependency breaks a build downstream.

BUG=None

Review-Url: https://codereview.webrtc.org/2630713002
Cr-Commit-Position: refs/heads/master@{#16047}
2017-01-13 13:56:16 +00:00
glaznev
21b6cce0c4 Do not report camera disconnected event if Android camera is closing.
Ignore CAMERA_ERROR_EVICTED error if camera is about to be closed.
This is valid use case when other app is opening camera while
WebRTC Android app is trying to close it.

BUG=b/34112992

Review-Url: https://codereview.webrtc.org/2627153002
Cr-Commit-Position: refs/heads/master@{#16039}
2017-01-12 21:05:47 +00:00
magjed
b66129a27e Fix JNI reference leak in MediaCodecVideoEncoder
We currently leak one local reference to MediaCodecVideoEncoder in
every call to MediaCodecVideoEncoderFactory::CreateVideoEncoder. After
the encoder has been re-initialized 512 times, JNI will crash due to
local reference table overflow (max=512).

The actual leak is in the member initializer list of
MediaCodecVideoEncoder. This CL fixes the leak by adding a
ScopedLocalRefFrame outside of the ctor. All JNI code that originate
from a C++ thread (i.e. the entry point is not a Java thread) must use
a ScopedLocalRefFrame in order to avoid leaking local references.

BUG=webrtc:6969,b/34056152

Review-Url: https://codereview.webrtc.org/2627973004
Cr-Commit-Position: refs/heads/master@{#16034}
2017-01-12 14:50:56 +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
nisse
ede5da4960 Replace ASSERT by RTC_DCHECK in all non-test code.
Bulk of the changes were produced using

  git grep -l ' ASSERT(' | grep -v test | grep -v 'common\.h' |\
    xargs -n1 sed -i 's/ ASSERT(/ RTC_DCHECK(/'

followed by additional includes of base/checks.h in affected files,
and git cl format.

Also had to do some tweaks to #if !defined(NDEBUG) logic in the
taskrunner code (webrtc/base/task.cc, webrtc/base/taskparent.cc,
webrtc/base/taskparent.h, webrtc/base/taskrunner.cc), replaced to
consistently use RTC_DCHECK_IS_ON, and some of the checks needed
additional #if protection.

Test code was excluded, because it should probably use RTC_CHECK
rather than RTC_DCHECK.

BUG=webrtc:6424

Review-Url: https://codereview.webrtc.org/2620303003
Cr-Commit-Position: refs/heads/master@{#16030}
2017-01-12 13:15:36 +00:00
nisse
eb4ca4e823 Replace RTC_DCHECK(false) with RTC_NOTREACHED().
Bulk of changes done using

  git grep -l 'RTC_DCHECK(false)' | \
    xargs sed -i 's/RTC_DCHECK(false)/RTC_NOTREACHED()/'

peerconnection.cc also used RTC_DCHECK(false && "msg") in two places,
which were updated manually.

BUG=webrtc:6424

Review-Url: https://codereview.webrtc.org/2623313004
Cr-Commit-Position: refs/heads/master@{#16026}
2017-01-12 10:24:27 +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
sakal
e1674efd2d Update Android instrumentation tests to use JUnit4.
BUG=webrtc:6597

Review-Url: https://codereview.webrtc.org/2627043002
Cr-Commit-Position: refs/heads/master@{#16011}
2017-01-11 14:22:56 +00:00
nisse
c80e741ad0 Replace ASSERT(false) by RTC_NOTREACHED().
This cl was produced by

  git grep -l 'ASSERT(false)' |\
    xargs -n1 sed -i 's/ASSERT(false)/RTC_NOTREACHED()/'

followed by additional includes of base/checks.h in affected files,
git cl format to adjust spacing in webrtc/base/transformadapter.cc.
Finally, to make presubmit happy, one unnamed TODO marker was deleted
in that file.

This is a step towards deletion of base/common.h.

BUG=webrtc:6424

Review-Url: https://codereview.webrtc.org/2625003003
Cr-Commit-Position: refs/heads/master@{#16009}
2017-01-11 13:56:46 +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
magjed
c0ce6cc85e Android: Wrap webrtc::field_trial::FindFullName in Java
The purpose is to be able to add field trials in Java code.

BUG=webrtc:6683

Review-Url: https://codereview.webrtc.org/2621003002
Cr-Commit-Position: refs/heads/master@{#15994}
2017-01-10 16:02:03 +00:00
nisse
af916899cc Move VideoFrame and related declarations to webrtc/api/video.
Moves webrtc/common_video/rotation.h and parts of
webrtc/common_video/include/video_frame_buffer.h and
webrtc/video_frame.h, and adds to a new GN target api:video_frame_api.

BUG=webrtc:5880

Review-Url: https://codereview.webrtc.org/2517173004
Cr-Commit-Position: refs/heads/master@{#15993}
2017-01-10 15:44:26 +00:00
sakal
e996a99721 Add a check for CameraCapturer being initialized before calling startCapture.
BUG=webrtc:6945
R=magjed@webrtc.org

Review-Url: https://codereview.webrtc.org/2621633002
Cr-Commit-Position: refs/heads/master@{#15988}
2017-01-10 12:30:31 +00:00
kthelgason
a3f6ce10ed Update bitrate adjustment with true buffer used size.
This used to be updated with the reserved capacity of the buffer,
not the actual portion in use.

BUG=webrtc:6034

Review-Url: https://codereview.webrtc.org/2620653005
Cr-Commit-Position: refs/heads/master@{#15982}
2017-01-10 11:02:04 +00:00
deadbeef
5d0b6d8da3 Merge RTCConfiguration with RTCMediaConstraints in Java/Obj-C wrappers.
The intention of SetConfiguration is that it modifies the configuration,
while keeping the constraints passed into CreatePeerConnection. Right
now that's now happening. See bug for more explanation.

BUG=webrtc:6942

Review-Url: https://codereview.webrtc.org/2603653002
Cr-Commit-Position: refs/heads/master@{#15974}
2017-01-10 00:05:28 +00:00
hnsl
0483362377 Add disabled certificate check support to IceServer PeerConnection API.
Refactor "OPT_SSLTCP" renaming it to "OPT_TLS_FAKE", making it clear
that it's not actually some kind of SSL over TCP. Also making it clear
that it's mutually exclusive with OPT_TLS. Maintaining deprecated
backwards compatible support for "OPT_SSLTCP".

Add "OPT_TLS_INSECURE" that implements the new certificate-check
disabled TLS mode, which is also mutually exclusive with the other
TLS options.

PortAllocator: Add a new TLS policy enum TlsCertPolicy which defines
the new insecure mode and added it as a RelayCredentials member.

TurnPort: Add new TLS policy member with appropriate getter and setter
to avoid constructor bloat. Initialize it from the RelayCredentials
after the TurnPort is created.

Expose the new feature in the PeerConnection API via
IceServer.tls_certificate_policy as well as via the Android JNI
PeerConnection API.

For security reasons we ensure that:

	1) The policy is always explicitly initialized to secure.
        2) API users have to explicitly integrate with the feature to
           use it, and will otherwise get no change in behavior.
	3) The feature is not immediately exposed in non-native
	   contexts. For example, disabling of certificate validation
           is not implemented via URI parsing since this would
           immediately allow it to be used from a web page.

This is a second attempt of https://codereview.webrtc.org/2557803002/
which was rolled back in https://codereview.webrtc.org/2590153002/

BUG=webrtc:6840

Review-Url: https://codereview.webrtc.org/2594623002
Cr-Commit-Position: refs/heads/master@{#15967}
2017-01-09 16:35:45 +00:00
magjed
0b7bd75659 AVFoundationVideoCapturer: Fix apply_rotation() logic
When apply_rotation() returns true, rotation and captured width/heigh are not set correctly.

BUG=webrtc:6925

Review-Url: https://codereview.webrtc.org/2611113003
Cr-Commit-Position: refs/heads/master@{#15963}
2017-01-09 15:09:23 +00:00
magjed
29fe6f338f Make magjed@ owner of webrtc/sdk/objc
Also, move owner file from webrtc/sdk to webrtc/sdk/objc since we now
also have webrtc/sdk/android directory.

BUG=None
TBR=tkchin
NOTRY=True

Review-Url: https://codereview.webrtc.org/2589233002
Cr-Commit-Position: refs/heads/master@{#15961}
2017-01-09 12:20:30 +00:00
mbonadei
438062bd43 Reland of Fixing package-boundary violation with srjar_deps (patchset #1 id:1 of https://codereview.webrtc.org/2617533005/ )
Reason for revert:
Skipping the build of the target "//webrtc/modules/audio_device:audio_device_java" when building webrtc with chromium.

This was causing a failure because in that case it is not possible to refer to the script used by the template "android_shared_srcjar" with an absolute path (which seems to be necessary since the script attribute of action is relative to the invocation target and not to the template declaration).

Original issue's description:
> Revert of Fixing package-boundary violation with srjar_deps (patchset #5 id:80001 of https://codereview.webrtc.org/2610823002/ )
>
> Reason for revert:
> This CL is breaking a chromium.webrtc.fyi: https://build.chromium.org/p/chromium.webrtc.fyi/builders/Android%20Builder/builds/226
>
> I am trying to reproduce the issue on my local machine and I will try to re-land the CL later.
>
> Original issue's description:
> > Fixing package-boundary violation with srjar_deps
> >
> > Without the usage of the srcjar_deps attribute we were not able to
> > include .java files from other packages without violating the package
> > boundary contraint.
> >
> > As an example, in this CL the target "libjingle_peerconnection_java" was
> > directly including .java files from another packages in its "java_files"
> > attribute.
> >
> > Using srcjar_deps we are able to declare the dependency of the target
> > avoiding to create hidden dependencies in the codebase.
> >
> > This is not fixing the webrtc:6356 bug directly but it is a first step to
> > include ThreadUtils classes in libjingle_peerconnection_client_java.jar
> > again.
> >
> > It seems also to be related to the chromium:648244 bug. This can be solved
> > if we can find a way to perform srcjar generation in the android_library
> > target without changing the semantic of the target.
> >
> > BUG=webrtc:6356
> >
> > Review-Url: https://codereview.webrtc.org/2610823002
> > Cr-Commit-Position: refs/heads/master@{#15914}
> > Committed: 10a76592a7
>
> TBR=kjellander@webrtc.org
> # Skipping CQ checks because original CL landed less than 1 days ago.
> NOPRESUBMIT=true
> NOTREECHECKS=true
> NOTRY=true
> BUG=webrtc:6356
>
> Review-Url: https://codereview.webrtc.org/2617533005
> Cr-Commit-Position: refs/heads/master@{#15915}
> Committed: eb731ed09e

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

Review-Url: https://codereview.webrtc.org/2612953004
Cr-Commit-Position: refs/heads/master@{#15958}
2017-01-09 10:37:21 +00:00
kthelgason
c1b661eee0 Remove duplicate implementations of string conversion methods.
BUG=webrtc:4773

Review-Url: https://codereview.webrtc.org/2583853002
Cr-Commit-Position: refs/heads/master@{#15957}
2017-01-09 09:40:03 +00:00