New file structure and targets:
rtc_stats_api
webrtc/api/stats/rtcstats.h
webrtc/api/stats/rtcstats_objects.h
webrtc/api/stats/rtcstatsreport.h
rtc_stats (dep on rtc_stats_api)
webrtc/stats/rtcstats.cc
webrtc/stats/rtcstats_objects.cc
webrtc/stats/rtcstatsreport.cc
libjingle_peerconnection (dep on rtc_stats)
webrtc/api/rtcstatscollector.cc
webrtc/api/rtcstatscollector.h
Placing rtc_stats_api headers in this separate target instead of
libjingle_peerconnection avoids a circular dependency
libjingle_peerconnection -> rtc_stats -> libjingle_peerconnection
Code changes:
PeerConnectionInterface::GetStats(RTCStatsCollectorCallback*) added for
the new stats collection API. Implemented by PeerConnection.
BUG=chromium:627816
Review-Url: https://codereview.webrtc.org/2331373004
Cr-Commit-Position: refs/heads/master@{#14246}
This is the stats collector for the new stats types, RTCStats[1] and
RTCStatsReport[2]. It so far only produces RTCPeerConnectionStats[3] as
an example of how it would collect stats. Each RTCStats subclass will
get a corresponding RTCStatsCollector::ProduceFooStats().
Stats reports are cached and returned as const references (ref
counting). This allows stats to be inspected by multiple observers and
across multiple threads. No copies will have to be made when surfacing
this to Blink or other places.
The current implementation of ProducePeerConnectionStats() only look at
existing DataChannels. This might be incorret if data channels can be
removed? Will investigate in a follow-up, crbug.com/636818.
[1] https://www.w3.org/TR/2016/WD-webrtc-20160531/#idl-def-rtcstats
[2] https://www.w3.org/TR/2016/WD-webrtc-20160531/#rtcstatsreport-object
[3] https://w3c.github.io/webrtc-stats/archives/20160526/webrtc-stats.html#pcstats-dict*
BUG=chromium:627816, chromium:636818
Review-Url: https://codereview.webrtc.org/2242043002
Cr-Commit-Position: refs/heads/master@{#13979}
The old and new getStats are very different. This CL proposes rewriting
the new getStats from scratch with a bottom-up approach, starting with
the fundamental stats classes. This will allow cleaner and more
efficient code that is more aligned with the spec.
RTCStats and subclasses are the equivalent to RTCStats and RTCStats-
-derived dictionaries from the specs[1][2]. The dictionary members are
public member variables of type RTCStatsMember<T>, where T is one of the
supported types. All members derive from RTCStatsMemberInterface and
iteration of members is possible with RTCStats::Members().
The members are not stored in a map for performance and readability.
Type checking is supported with static class variables, kType.
Only the supported member types T are specialized and may be
instantiated, and sequences are supported with std::vector<...>. Type
checking is again supported with static class variables, kType.
RTCStatsReport is the equivalent from the spec[3], and maps RTCStats::id
to RTCStats-objects. RTCStatsReport is reference counted. It and its
contained stats may be destroyed on any thread. When the
RTCStatsCollector is added in a follow-up CL, it will return const
references to the RTCStatsReports. This means copies don't have to be
made for multiple stats observers or when jumping threads. In fact, no
copies of any stats will have to be made in surfacing stats to Blink.
[1] https://www.w3.org/TR/2016/WD-webrtc-20160531/#rtcstats-dictionary
[2] https://w3c.github.io/webrtc-stats/archives/20160526/webrtc-stats.html
[3] https://www.w3.org/TR/2016/WD-webrtc-20160531/#rtcstatsreport-object
This adds the new folder webrtc/stats/, with target rtc_stats and binary
rtc_stats_unittests. Public api headers are placed in webrtc/api/ and
.cc files are placed in webrtc/stats/.
BUG=chromium:627816
Review-Url: https://codereview.webrtc.org/2241093002
Cr-Commit-Position: refs/heads/master@{#13879}
This is needed for webrtc::field_trial::FindFullName in peerconnection.cc
NOTRY=True
Review-Url: https://codereview.webrtc.org/2120673004
Cr-Commit-Position: refs/heads/master@{#13836}
stack will be removed soon in a separate CL. Constraints will not be supported
in the new implementation. Apps can request a format directly and the closest
supported format will be selected.
Changes needed from the apps:
1. Use the new createVideoSource without constraints.
2. Call startCapture manually.
3. Don't call videoSource.stop/restart, use startCapture/stopCapture instead.
R=magjed@webrtc.orgTBR=kjellander@webrtc.org
Review URL: https://codereview.webrtc.org/2127893002 .
Cr-Commit-Position: refs/heads/master@{#13504}
This interface and its implementations have been replaced by
rtc::RTCCertificateGeneratorInterface.
Removes dtlsidentitystore.h, updates .gyp/gn and removes old #includes.
BUG=webrtc:5707, webrtc:5708
Review-Url: https://codereview.webrtc.org/2034013003
Cr-Commit-Position: refs/heads/master@{#13432}
Reason for revert:
Issues fixed
Original issue's description:
> Revert of Combine webrtc/api/java/android and webrtc/api/java/src. (patchset #1 id:1 of https://codereview.webrtc.org/2111823002/ )
>
> Reason for revert:
> Breaks downstream dependencies
>
> Original issue's description:
> > Combine webrtc/api/java/android and webrtc/api/java/src.
> >
> > It used to be that there was a Java api for devices not running Android
> > but that is no longer the case. I combined the directories and made
> > the folder structure chromium style.
> >
> > BUG=webrtc:6067
> > R=magjed@webrtc.org, tommi@webrtc.org
> >
> > Committed: ceefe20dd6
>
> TBR=magjed@webrtc.org,tommi@webrtc.org
> # Skipping CQ checks because original CL landed less than 1 days ago.
> NOPRESUBMIT=true
> NOTREECHECKS=true
> NOTRY=true
> BUG=webrtc:6067
>
> Committed: 9b0dc622d4TBR=magjed@webrtc.org,tommi@webrtc.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=webrtc:6067
Review-Url: https://codereview.webrtc.org/2111923003
Cr-Commit-Position: refs/heads/master@{#13363}
Reason for revert:
Breaks downstream dependencies
Original issue's description:
> Combine webrtc/api/java/android and webrtc/api/java/src.
>
> It used to be that there was a Java api for devices not running Android
> but that is no longer the case. I combined the directories and made
> the folder structure chromium style.
>
> BUG=webrtc:6067
> R=magjed@webrtc.org, tommi@webrtc.org
>
> Committed: ceefe20dd6TBR=magjed@webrtc.org,tommi@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=webrtc:6067
Review URL: https://codereview.webrtc.org/2106333005 .
Cr-Commit-Position: refs/heads/master@{#13357}
It used to be that there was a Java api for devices not running Android
but that is no longer the case. I combined the directories and made
the folder structure chromium style.
BUG=webrtc:6067
R=magjed@webrtc.org, tommi@webrtc.org
Review URL: https://codereview.webrtc.org/2111823002 .
Cr-Commit-Position: refs/heads/master@{#13356}
Relanding again after fixing issue with RTC_DCHECKs.
This CL eliminates the need for the extra layer of indirection provided by
mediastreamprovider.h. It will thus make it easier to implement new
functionality in RtpSender/RtpReceiver.
It also brings us one step closer to the end goal of combining "senders"
and "send streams". Currently the sender still needs to go through the
BaseChannel and MediaChannel, using an SSRC as a key.
R=pthatcher@webrtc.org
Review URL: https://codereview.webrtc.org/2046173002 .
Cr-Commit-Position: refs/heads/master@{#13305}
Reason for revert:
Broke video sending for iOS AppRTCDemo. To repro, run iOS AppRTCDemo in Release in loopback mode. The revision prior to this change worked.
Original issue's description:
> Reland of: Use VoiceChannel/VideoChannel directly from RtpSender/RtpReceiver.
>
> This eliminates the need for the extra layer of indirection provided by
> mediastreamprovider.h. It will thus make it easier to implement new
> functionality in RtpSender/RtpReceiver.
>
> It also brings us one step closer to the end goal of combining "senders"
> and "send streams". Currently the sender still needs to go through the
> BaseChannel and MediaChannel, using an SSRC as a key.
>
> R=pthatcher@webrtc.org
>
> Committed: 2d5491783aTBR=pthatcher@webrtc.org,deadbeef@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
Review-Url: https://codereview.webrtc.org/2092273003
Cr-Commit-Position: refs/heads/master@{#13289}
This eliminates the need for the extra layer of indirection provided by
mediastreamprovider.h. It will thus make it easier to implement new
functionality in RtpSender/RtpReceiver.
It also brings us one step closer to the end goal of combining "senders"
and "send streams". Currently the sender still needs to go through the
BaseChannel and MediaChannel, using an SSRC as a key.
R=pthatcher@webrtc.org
Review URL: https://codereview.webrtc.org/2046173002 .
Cr-Commit-Position: refs/heads/master@{#13287}
Reason for revert:
Broke peerconnection_unittest somehow, due to introduction of thread check. Will fix and reland.
Original issue's description:
> Use VoiceChannel/VideoChannel directly from RtpSender/RtpReceiver.
>
> This eliminates the need for the extra layer of indirection provided by
> mediastreamprovider.h. It will thus make it easier to implement new
> functionality in RtpSender/RtpReceiver.
>
> It also brings us one step closer to the end goal of combining "senders"
> and "send streams". Currently the sender still needs to go through the
> BaseChannel and MediaChannel, using an SSRC as a key.
>
> R=pthatcher@webrtc.org
>
> Committed: https://crrev.com/bc5831999d3354509d75357b659b4bb8e39f8a6c
> Cr-Commit-Position: refs/heads/master@{#13285}
TBR=pthatcher@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
Review-Url: https://codereview.webrtc.org/2099843003
Cr-Commit-Position: refs/heads/master@{#13286}
This eliminates the need for the extra layer of indirection provided by
mediastreamprovider.h. It will thus make it easier to implement new
functionality in RtpSender/RtpReceiver.
It also brings us one step closer to the end goal of combining "senders"
and "send streams". Currently the sender still needs to go through the
BaseChannel and MediaChannel, using an SSRC as a key.
R=pthatcher@webrtc.org
Review URL: https://codereview.webrtc.org/2046173002 .
Cr-Commit-Position: refs/heads/master@{#13285}
In GN, the libjingle_peerconnection_jni target becomes a part of
'all' implicitly, which surfaced the incompability between it
and the Chromium logging implementation. In the GYP build, the
target is not present due to api.gyp not being depended upon yet.
BUG=webrtc:4256
TBR=perkj@webrtc.org
NOTRY=True
Review-Url: https://codereview.webrtc.org/2082573004
Cr-Commit-Position: refs/heads/master@{#13231}
In order to switch Chromium to use WebRTC targets instead of
duplicated code listings in src/third_party/libjingle it must
be possible for Chromium to process webrtc/api/api.gyp. This is
currently not possible since it includes build/java.gypi, of which
the path is different in a Chromium checkout. It's not possible
to resolve this in another way since 'includes' processing takes
place early in the GYP cycle, before it's possible to use variables.
They're also processed ignoring conditional statements, resulting
in an error when api.gyp is processed.
BUG=webrtc:4256
TBR=perkj@webrtc.org
NOTRY=True
Review-Url: https://codereview.webrtc.org/2080563002
Cr-Commit-Position: refs/heads/master@{#13208}
This CL turns nativeConfiguration into createNativeConfiguration returning a
pointer or nil on failure. This method's certificate generation is updated to
use the new API and reports failure (nil) if unsuccessful instead of relying on
the default certificate. We also remove the implicit assumption (now incorrect)
that RSA is the default. This is the same type of changes as was done in
https://codereview.webrtc.org/1965313002 but this file
(RTCPeerConnectionInterface.mm) was forgotten.
With no more usages of kIdentityName it and dtlsidentitystore.cc is removed.
Also removes unnecessary #include in peerconnectioninterface.h that was still
remnant due to an indirect include of kIdentityName.
RTCConfiguration+Private.h now lists method nativeEncryptionKeyTypeForKeyType
which was added in the above mentioned prior CL.
BUG=webrtc:5707, webrtc:5708
Review-Url: https://codereview.webrtc.org/2035473004
Cr-Commit-Position: refs/heads/master@{#13089}
By not providing the default implementation of the metrics API
it becomes possible for users of rtc_media to choose which
implementation to use. The dependency is moved into each test
target that uses it instead.
NOTRY=True
NOPRESUBMIT=True
Review-Url: https://codereview.webrtc.org/2026223002
Cr-Commit-Position: refs/heads/master@{#12991}
QuicDataChannel implements DataChannelInterface. It
replaces SCTP data channels by using a QuicTransportChannel
to create a ReliableQuicStream for each message.
QuicDataChannel only implements unordered, reliable delivery
for the initial implementation and does not send a hello message.
QuicDataTransport is a helper class that dispatches each incoming
ReliableQuicStream to a QuicDataChannel when the remote
peer receives a message by parsing the data channel id and message id
from the message header. It is also responsible for encoding the header
before QuicDataChannel sends the message.
Split from CL https://codereview.chromium.org/1844803002/.
BUG=
Review-Url: https://codereview.webrtc.org/1886623002
Cr-Commit-Position: refs/heads/master@{#12574}
- Places most ObjC code into webrtc/sdk/objc instead.
- New gyp targets to build, strip and export symbols for dylib.
- Removes old script used to generate dylib.
BUG=
Review URL: https://codereview.webrtc.org/1903663002
Cr-Commit-Position: refs/heads/master@{#12524}
This change adds the Objective C API functions to get and set RtpSender's
RtpParameters, which allows setting bitrate limits for audio and video and
turning off RtpSenders to pre-initialize the encoder.
This CL adds only the smallest set of methods required to support bitrate
limiting - there is no way to create an RtpSender, for example, or to set
its track. The only supported functionality is this:
RTCPeerConnection.senders - a read-only property returning the array
of all RTCRtpSenders for the connection.
RTCRtpSender.parameters - a read-only property returning the current
parameters
RTCRtpSender.setParameters: - a method to change the parameters.
RTCRtpSender.track - a read-only property returning the
RTCMediaStreamTrack corresponding to the sender. It is necessary
to be able to identify RTCRtpSenders for video and audio. The
track object is of the base RTCMediaStreamTrack type, not of the
specific subclass for audio and video - just like it is in the
Java API.
BUG=
Review URL: https://codereview.webrtc.org/1854393002
Cr-Commit-Position: refs/heads/master@{#12297}
This remove the use of VideoTrackRenderers within VideoTrack and instead all its sinks are passed to VideoSource.
That means that the source will handle all sinks and can (if the source implement it) handle different SinkWants for each sink.
The VideoBroadcaster is updated to produce black frames instead of as is today the deprecated VideoTrackRenderers.
BUG=webrtc:5426
R=nisse@webrtc.org, pthatcher@webrtc.org
Review URL: https://codereview.webrtc.org/1779063003 .
Cr-Commit-Position: refs/heads/master@{#12028}
This change allows the application to limit the bitrate of the outgoing
audio and video streams at runtime. The API roughly follows the WebRTC
API draft, defining the RTCRtpParameters structure witn exactly one
encoding (simulcast streams are not exposed in the API for now).
(https://www.w3.org/TR/webrtc/#idl-def-RTCRtpParameters)
BUG=
Review URL: https://codereview.webrtc.org/1788583004
Cr-Commit-Position: refs/heads/master@{#12025}
VideoTrackSource will be implemented in an upcoming cl but is needed to be included in libjingle.gyp in Chrome before the cl can be landed.
R=kjellander@webrtc.org
Review URL: https://codereview.webrtc.org/1769343003 .
Cr-Commit-Position: refs/heads/master@{#11897}
Moved VideoSourceInterface to MediaStreamInterface.h
Renamed VideoSourceTest to VideoCapturerTrackSourceTest
Renamed VideoSource to VideoCaptureTrackSource and cl lint and cl format.
BUG=webrtc:5426
TBR=pthatcher@webrtc.org
Review URL: https://codereview.webrtc.org/1770003002 .
Cr-Commit-Position: refs/heads/master@{#11893}
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}
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}
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}