One reason for the circular deps is that common_types.h is a
historical dumping ground for various structs and defines that
are believed to be generally useful. I tried moving things out
that did not appear to be used downstream (StreamCounters,
RtpCounters etc) and moved the things that seemed used
(RtpHeader + supporting structs) to a new file api/rtp_headers.h.
This makes their place in the api more clear while moving out
the things that don't belong in the API in the first place.
I had to extract out typedefs.h from webrtc_common to resolve
another circular dependency. I believe checks includes typedefs,
but common depends on checks.
Bug: webrtc:7745
Change-Id: I725d49616b1ec0cdc8b74be7c078f7a4d46f084b
Reviewed-on: https://webrtc-review.googlesource.com/33001
Commit-Queue: Patrik Höglund <phoglund@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#21295}
This CL removes the following GN variables: rtc_build_libyuv,
rtc_libyuv_dir (as requested in webrtc:7906).
It also removes some unneeded dependencies on //third_party/libyuv.
WebRTC targets were using public_deps to depend on //third_party/libyuv
and this created a build graph where targets that were depending on
//third_party/libyuv were not declaring the dependency to GN because
they were somehow getting it from another target that was exposing
//third_party/libyuv header files even if it wasn't directly depending
on it.
Bug: webrtc:8605, webrtc:7906
Change-Id: If71f7988fd80421dc2ad887cf94c2ac66366c3fb
Reviewed-on: https://webrtc-review.googlesource.com/32201
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Patrik Höglund <phoglund@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#21275}
This splits things out of rtc_base and makes dependencies explicit.
Bug: webrtc:6828
Change-Id: Id521896c3c43595349021c857bec216e429a0c8d
Reviewed-on: https://webrtc-review.googlesource.com/32780
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Patrik Höglund <phoglund@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#21264}
This splits things out of rtc_base and makes dependencies explicit.
Bug: webrtc:6828
Change-Id: Ib813c7bd9e4de7ab015acb917bc09ee7204ba7bd
Reviewed-on: https://webrtc-review.googlesource.com/31940
Commit-Queue: Patrik Höglund <phoglund@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#21245}
The problem was that the encoder was feeded with frames that had 0 as
a timestamp. This confused the encoder. H264 high profile support
clause was also wrong and is corrected.
Bug: webrtc:8601
Change-Id: Ic5a893b4b7573e694f865b63620843b2c9aa489f
Reviewed-on: https://webrtc-review.googlesource.com/32300
Reviewed-by: Magnus Jedvert <magjed@webrtc.org>
Reviewed-by: Rasmus Brandt <brandtr@webrtc.org>
Commit-Queue: Sami Kalliomäki <sakal@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#21234}
Using fully qualified paths to include libyuv headers allows WebRTC to
avoid to rely on the //third_party/libyuv:libyuv_config target to
set the -I compiler flag.
Today some WebRTC targets depend on //third_party/libyuv only to
include //third_party/libyuv:libyuv_config but with fully qualified
paths this should not be needed anymore.
A follow-up CL will remove //third_party/libyuv from some targets that
don't need it because they are not including libyuv headers.
Bug: webrtc:8605
Change-Id: Icec707ca761aaf2ea8088e7f7a05ddde0de2619a
No-Try: True
Reviewed-on: https://webrtc-review.googlesource.com/28220
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Magnus Flodman <mflodman@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#21209}
The generated JNI files are actually implementation files that can only
be included from one place. For generating JNI code for
PeerConnection.java, this means we need to collect all JNI
PeerConnection code into one place. This CL moves
peerconnectionobserver_jni.h to peerconnection.h, and merges
peerconnectionobserver_jni.cc and peerconnection_jni.cc. It also moves
converter functions JavaToNativeIceServers and
JavaToNativeRTCConfiguration to peerconnection.h since they are also
related to PeerConnection.java.
This CL does not contain anything else than a pure code move.
TBR=sakal@webrtc.org
Bug: webrtc:8278
Change-Id: I31c696c1aab495e09f95e5ba5d79f95df7c34a0e
Reviewed-on: https://webrtc-review.googlesource.com/31483
Reviewed-by: Magnus Jedvert <magjed@webrtc.org>
Commit-Queue: Magnus Jedvert <magjed@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#21200}
This moves all WebRTC internal code from using
SessionDescriptionInterface::type() which returns a string and
from using CreateSessionDescription with a string type parameter.
Bug: webrtc:8613
Change-Id: I1cdd93dc4b26dec157e22476fdac569d5da2810a
Reviewed-on: https://webrtc-review.googlesource.com/29500
Commit-Queue: Steve Anton <steveanton@webrtc.org>
Reviewed-by: Magnus Jedvert <magjed@webrtc.org>
Reviewed-by: Zhi Huang <zhihuang@webrtc.org>
Reviewed-by: Peter Thatcher <pthatcher@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#21147}
A lot of WebRTC targets were depending on //third_party/libyuv using
public_deps instead of deps. This causes issues because a the
inclusion of libyuv headers is not declared to the build system and
this creates hidden dependencies that put the modularity of the project
at risk.
Bug: webrtc:8603
Change-Id: Ide0ceb84eb5640ae664dc782f3a722b55c3b601a
No-Try: True
Reviewed-on: https://webrtc-review.googlesource.com/28120
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Magnus Flodman <mflodman@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#21039}
Changes places where we explicitly construct an Optional to instead use
nullopt or the requisite value type only.
This CL was uploaded by git cl split.
Bug: None
Change-Id: Idf275495910f651ec35f641611926e62414daa9a
Reviewed-on: https://webrtc-review.googlesource.com/23610
Commit-Queue: Oskar Sundbom <ossu@webrtc.org>
Reviewed-by: Sami Kalliomäki <sakal@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#20972}
This reverts commit aede67a199.
Reason for revert: Causes error:
JNI ERROR (app bug): local reference table overflow (max=512)'
Original change's description:
> Android: Generate JNI code for stats
>
> This CL also unifies the functions for converting from C++ to Java, and
> generates the boiler plate for converting C++ vectors to Java arrays.
>
> Bug: webrtc:8278
> Change-Id: I262e9162beae8a64ba0e8b6a27e1081207b03961
> Reviewed-on: https://webrtc-review.googlesource.com/26020
> Commit-Queue: Magnus Jedvert <magjed@webrtc.org>
> Reviewed-by: Sami Kalliomäki <sakal@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#20918}
TBR=magjed@webrtc.org,sakal@webrtc.org
Change-Id: Ieb26ed8577bd489a4dd4f7542d16a7d0e11f409f
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: webrtc:8278
Reviewed-on: https://webrtc-review.googlesource.com/26900
Reviewed-by: Magnus Jedvert <magjed@webrtc.org>
Commit-Queue: Magnus Jedvert <magjed@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#20926}
This CL also unifies the functions for converting from C++ to Java, and
generates the boiler plate for converting C++ vectors to Java arrays.
Bug: webrtc:8278
Change-Id: I262e9162beae8a64ba0e8b6a27e1081207b03961
Reviewed-on: https://webrtc-review.googlesource.com/26020
Commit-Queue: Magnus Jedvert <magjed@webrtc.org>
Reviewed-by: Sami Kalliomäki <sakal@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#20918}
Also improves ownership model by using std::unique_ptr in a couple of
places instead of raw pointers.
Bug: webrtc:8278
Change-Id: I0429ec3c416b5baa1ffa21dad71e0d64b004c446
Reviewed-on: https://webrtc-review.googlesource.com/25020
Commit-Queue: Magnus Jedvert <magjed@webrtc.org>
Reviewed-by: Sami Kalliomäki <sakal@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#20863}
This is not the case for fallback codecs.
Bug: webrtc:7925
Change-Id: I5039d8879923a2db1e7c08bb5640763dd20ea8e7
Reviewed-on: https://webrtc-review.googlesource.com/24863
Commit-Queue: Sami Kalliomäki <sakal@webrtc.org>
Reviewed-by: Magnus Jedvert <magjed@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#20861}
It's now possible to generate JNI code for constructors and enums
correctly. This CL cleans that up.
Bug: webrtc:8278,webrtc:8551,webrtc:8556
Change-Id: I2284a30139cbb186c80713eb6113eda5659c16ad
Reviewed-on: https://webrtc-review.googlesource.com/25622
Reviewed-by: Sami Kalliomäki <sakal@webrtc.org>
Commit-Queue: Magnus Jedvert <magjed@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#20860}
Previously, wrapped native codec instances would leak the native object
if it was never used. This change fixes it by changing getNative method
to createNative.
Also fixes "Video codec hardware acceleration" setting in AppRTCMobile.
Bug: webrtc:7925
Change-Id: I53f6dc1dd5e37dea8d14278423122dede17719c5
Reviewed-on: https://webrtc-review.googlesource.com/24881
Reviewed-by: Magnus Jedvert <magjed@webrtc.org>
Commit-Queue: Sami Kalliomäki <sakal@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#20859}
Unfortunately, H264 makes it non-trivial to compare video formats for
equality. For every video format besides H264 it's enough to look at the
name, but for H264, we need to dig into the parameters. This logic is
currently in several places, and this CL unifies it to one place.
Bug: webrtc:7925
Change-Id: I83a516b108d6b4d6792fd0bf1d24296916d9f7fa
Reviewed-on: https://webrtc-review.googlesource.com/25120
Commit-Queue: Magnus Jedvert <magjed@webrtc.org>
Reviewed-by: Sami Kalliomäki <sakal@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#20853}
Previously Java 8 bytecode was transpiled into Java 7 bytecode for AAR.
With this change we instead include Java 8 bytecode in the AAR.
This drops support for Java 7 but allows using Java 8 features such as
static methods in interfaces and default methods.
Bug: webrtc:8084, chromium:762967
Change-Id: I3c6ec9332c5612b7ed811a81957f25c94c80da70
No-Try: True
Reviewed-on: https://webrtc-review.googlesource.com/21222
Commit-Queue: Sami Kalliomäki <sakal@webrtc.org>
Reviewed-by: Magnus Jedvert <magjed@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#20849}
The current names are too long and make the stats screen in
AppRTCMobile unusable.
Bug: None
Change-Id: I5c4d0526e478ff45392f80a8bb22c2d97f63de17
Reviewed-on: https://webrtc-review.googlesource.com/25481
Commit-Queue: Sami Kalliomäki <sakal@webrtc.org>
Reviewed-by: Magnus Jedvert <magjed@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#20847}
Changes places where we explicitly construct an Optional to instead use
nullopt or the requisite value type only.
This CL was uploaded by git cl split.
R=sakal@webrtc.org
Bug: None
Change-Id: Ib01eb9ef7b3b76c0f55890d7ea1b8dfcd30f0617
Reviewed-on: https://webrtc-review.googlesource.com/23607
Reviewed-by: Sami Kalliomäki <sakal@webrtc.org>
Commit-Queue: Oskar Sundbom <ossu@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#20845}
capture_time_ms_ is always 0 for frames received from the network. This
caused a bug because it was used as an unique identified.
Bug: b/68271454
Change-Id: Ic4417a52e61cf2b0cd796a89207a90b603a16590
Reviewed-on: https://webrtc-review.googlesource.com/24940
Reviewed-by: Magnus Jedvert <magjed@webrtc.org>
Commit-Queue: Sami Kalliomäki <sakal@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#20837}
This makes the receiver know about its associated set of streams, the
equivalent of the [[AssociatedRemoteMediaStreams]] slot in the spec,
https://w3c.github.io/webrtc-pc/#dfn-x%5B%5Bassociatedremotemediastreams%5D%5D
This does not change layers below peerconnection.cc. The streams are set
upon the receiver's construction and is not modified for the duration of
its lifetime.
When we support modifying the associated set of streams of a receiver
the receiver needs to know about it. The receiver's streams() should be
used in all places where a receiver's streams need to be known.
Bug: webrtc:8473
Change-Id: I31202973aed98e61fa9b6a78b52e815227b6c17d
Reviewed-on: https://webrtc-review.googlesource.com/22922
Reviewed-by: Peter Thatcher <pthatcher@webrtc.org>
Reviewed-by: Magnus Jedvert <magjed@webrtc.org>
Reviewed-by: Steve Anton <steveanton@webrtc.org>
Commit-Queue: Henrik Boström <hbos@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#20825}
This is a debug feature and should be disabled by default. Any client
that needs this functionality should call setEnableInternalTracer.
Bug: webrtc:8553
Change-Id: I78d718ebb95fc5cb8c464327b5b36e385ccfa9c0
Reviewed-on: https://webrtc-review.googlesource.com/24540
Commit-Queue: Sami Kalliomäki <sakal@webrtc.org>
Reviewed-by: Magnus Jedvert <magjed@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#20814}
We can call name() on the base class java.lang.Enum instead of the
specific enum subclass.
Bug: webrtc:8278
Change-Id: I12f8354d99e48b4a5e3d3eaff74a85ac417df0b3
Reviewed-on: https://webrtc-review.googlesource.com/24440
Commit-Queue: Magnus Jedvert <magjed@webrtc.org>
Reviewed-by: Sami Kalliomäki <sakal@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#20790}