Their base class, Transport, still exists, but it now has a more specific
role: a helper class that applies TransportDescriptions. And is renamed
to JsepTransport as a result.
TransportController is now the entity primarily responsible for managing
TransportChannels. It also starts storing pointers to the DTLS and ICE
chanels separately, which will make it easier to remove
TransportChannel/TransportChannelImpl in a subsequent CL.
BUG=None
Review-Url: https://codereview.webrtc.org/2517883002
Cr-Commit-Position: refs/heads/master@{#15450}
I decided to make one webrtc/sdk/android/BUILD.gn for both tests and Java/jni src.
External dependencies needs to be updated after this CL.
Future work is required to clean up the Android api and move
implementation details to /webrtc/sdk/android/src.
BUG=webrtc:5882,webrtc:6804
NOPRESUBMIT=True
Review-Url: https://codereview.webrtc.org/2547483003
Cr-Commit-Position: refs/heads/master@{#15443}
Change the second parameter type to a const reference of vector so that
the vector will not be copied.
BUG=none
Review-Url: https://codereview.webrtc.org/2551603003
Cr-Commit-Position: refs/heads/master@{#15396}
This is in preparation for https://codereview.webrtc.org/2517173004/,
which needs some updates of downstream dependencies. This cl adds the
target to api/BUILD.gn, creates the directory api/video, and a single
harmless include file there.
BUG=webrtc:5880
Review-Url: https://codereview.webrtc.org/2546723003
Cr-Commit-Position: refs/heads/master@{#15385}
QualityScaler may scale down the resolution, so our tests shouldn't
expect the input resolution to exactly match the resolution received on
the other side. Instead, we now just check that the aspect ratio
matches.
BUG=webrtc:5907
Review-Url: https://codereview.webrtc.org/2547673002
Cr-Commit-Position: refs/heads/master@{#15373}
This change makes the Java classes and constructors for
SurfaceTextureHelper and I420Frame public. This allows applications to
use the WebRTC CameraVideoCapturer to obtain raw frames, and to render
frames on the WebRTC VideoRenderer without having to pass them through a
VideoTrack - such as when using Quartc.
BUG=None.
Review-Url: https://codereview.webrtc.org/2544563002
Cr-Commit-Position: refs/heads/master@{#15344}
We already have an implementation in h264_common. We should have
as few of these as possible as they are subtly hard to get right
and it creates work to maintain N implementations.
BUG=webrtc:6546
Review-Url: https://codereview.webrtc.org/2538133002
Cr-Commit-Position: refs/heads/master@{#15336}
RTCIceCandidatePairStats.transport_id is set to the related
RTCTransportStats' id.
Unittest for RTCIceCandidatePairStats is updated to do EXPECT_EQ
between actual and an expected hardcoded dictionary. The previous way of
testing, ExpectReportContainsCandidatePair, is removed.
(ExpectReportContainsCandidate still exist, we might want to replace
this by EXPECT_EQ testing in a follow up.)
Unittest for RTCTransportStats is similarly updated and
ExpectReportContainsTransportStats is removed. A bug was uncovered where
the "rtcp_connection_info.best_connection = true" case was not tested
(a copy of rtcp_connection_info was used in the test, modifying that had
no affect on the test) - fixed.
rtcstats_integrationtest.cc updated to take transport_id into account.
In order to reuse an updated version of expected_rt[c]p_transport in the
unittest, timestamps are ignored by RTCStats::operator==.
BUG=chromium:627816, chromium:653873, chromium:653873, webrtc:6755
Review-Url: https://codereview.webrtc.org/2527113002
Cr-Commit-Position: refs/heads/master@{#15316}
This is an integration test using peerconnectiontestwrapper.h to set up
and end to end test using a real PeerConnection implementation. These
tests will complement rtcstatscollector_unittest.cc which collects all
stats using mocks.
The integration test is set up so that all stats types are returned by
GetStats and verifies that expected dictionary members are defined. The
test could in the future be updated to include sanity checks for the
values of members. There is a sanity check that references to other
stats dictionaries yield existing stats of the appropriate type, but
other than that members are only tested for if they are defined not.
StatsCallback of rtcstatscollector_unittest.cc is moved so that it can
be reused and renamed to RTCStatsObtainer.
TODO: Audio stream track stats members are missing in the test. Find out
if this is because of a real problem or because of testing without real
devices. Do this before closing crbug.com/627816.
BUG=chromium:627816
Review-Url: https://codereview.webrtc.org/2521663002
Cr-Commit-Position: refs/heads/master@{#15287}
This brings QualityScaler much more in line with OveruseFrameDetector.
The two classes are conceptually similar, and should be used in the
same way. The biggest changes in this CL are:
- Quality scaling is now only done in ViEEncoder and not in each
encoder implementation separately.
- QualityScaler now checks the average QP asynchronously, instead of
having to be polled on each frame.
- QualityScaler is no longer responsible for actually scaling the frames,
but has a callback to ViEEncoder that it uses to express it's desire
for lower resolution.
BUG=webrtc:6495
Review-Url: https://codereview.webrtc.org/2398963003
Cr-Commit-Position: refs/heads/master@{#15286}
Previously, a frame queued before calling addFrameListener could be
passed to the listener. Also fixes an issue where listener could still
be called after removeFrameListener call returned.
BUG=webrtc:6470
Review-Url: https://codereview.webrtc.org/2529313002
Cr-Commit-Position: refs/heads/master@{#15275}
This logic doesn't really work. Application should mask the view while
the surface size is being changed.
BUG=webrtc:6470
Review-Url: https://codereview.webrtc.org/2528243003
Cr-Commit-Position: refs/heads/master@{#15273}
transport.h defines an interface for sending rtp and rtcp packets,
which is used by MediaChannel in webrtc/media/engine,
{Audio|Video}{Send|Receive}Stream and in a few other
places. It was part of the build target //webrtc:webrtc, which is a monolithic target with
all webrtc production code. This CL moves the header to its own target in webrtc/api
and deprecates the old location.
Targets in webrtc/api should in general only depend on other
targets in webrtc/api. The target webrtc/api:call_api depends on
transport.h. This change also makes webrtc/voice_engine pass GN's header
include checker and is needed in order for webrtc/api:call_api to pass
it.
transport.h will be completely removed in a follow-up CL in a few weeks
after clients have updated their includes.
NOTRY=True
BUG=webrtc:5589, webrtc:5878, webrtc:6785
Review-Url: https://codereview.webrtc.org/2426563003
Cr-Commit-Position: refs/heads/master@{#15267}
The Android HW encoder is currently not setting any H264 codec parameters or profile information. No profile-level-id means Baseline Level 1, but we are actually using Contrained Baseline Level 3.1. This CL sets the correct codec parameters.
BUG=webrtc:6337
Review-Url: https://codereview.webrtc.org/2497163002
Cr-Commit-Position: refs/heads/master@{#15247}
Change the default value of rtcp-mux policy in RTCConfiguration.
Refactor the peerconnectioninterface and webrtcsession unit tests.
BUG=webrtc:6030
Review-Url: https://codereview.webrtc.org/2043193003
Cr-Commit-Position: refs/heads/master@{#15217}
I forget to remove these when fixing them.
BUG=chromium:636818
NOTRY=True
NOPRESUBMIT=True
Review-Url: https://codereview.webrtc.org/2522023003
Cr-Commit-Position: refs/heads/master@{#15215}
There shouldn't be a need to bind the framebuffer to modify the texture
size. Binding the framebuffer causes a crash on Samsung Galaxy S3 mini
for some reason.
BUG=webrtc:6470
Review-Url: https://codereview.webrtc.org/2524003002
Cr-Commit-Position: refs/heads/master@{#15210}
RTCStatsCollector supports "payloadType", "codec" and "clockRate".
"channels", "parameters" and "implementation" need to be supported
before closing crbug.com/659117.
[1] https://w3c.github.io/webrtc-stats/#codec-dict*
BUG=chromium:659117, chromium:627816, chromium:657854
NOTRY=True
Review-Url: https://codereview.webrtc.org/2509803004
Cr-Commit-Position: refs/heads/master@{#15207}
Set the |qp_| field in EncodedImage before calling OnEncodedImage.
BUG=webrtc:6541
Review-Url: https://codereview.webrtc.org/2499003002
Cr-Commit-Position: refs/heads/master@{#15199}
The mock is used in a dependent CL https://codereview.webrtc.org/2436033002.
There is also a goal to allow external mixing implementations
(subclasses of webrtc::AudioMixer) and inject them to
PeerConnectionFactory. We think that part of that is an official and
maintained mock.
Summary of changes:
* Created a mixer mock/stub in webrtc/api/test
* Made a target webrtc/api:mock_audio_mixer for it.
NOTRY=True
BUG=webrtc:6346
Review-Url: https://codereview.webrtc.org/2520323002
Cr-Commit-Position: refs/heads/master@{#15190}
Previously this was only collected for RTCOutboundRTPStreamStats video,
with no comment saying it was missing for Inbound. (nack_count should be
collected vor audio as well but this is currently not available - there
is already an existing comment about this in rtcstats_objects.h.)
BUG=chromium:657855, chromium:657854, chromium:627816
Review-Url: https://codereview.webrtc.org/2515293002
Cr-Commit-Position: refs/heads/master@{#15185}
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}
This file fits there more naturally since it has dependencies to jni.
BUG=None
Review-Url: https://codereview.webrtc.org/2514383002
Cr-Commit-Position: refs/heads/master@{#15179}
This allows downstream dependencies can add it as a dependency.
BUG=webrtc:6499
Review-Url: https://codereview.webrtc.org/2521183002
Cr-Commit-Position: refs/heads/master@{#15178}
a == b would return true if a.member is defined even if b.member is
undefined if their values were equal. We would say that b does not have
a value in that case but its value_ member would still be initialized to
something that is being compared to. Bugfix makes sure not to do value
comparison in this case if b is undefined.
BUG=chromium:627816
Review-Url: https://codereview.webrtc.org/2517163002
Cr-Commit-Position: refs/heads/master@{#15172}
Make magjed@ owner of whole webrtc/api/android/ and remove him as owner of subfolders.
BUG=None
NOTRY=True
Review-Url: https://codereview.webrtc.org/2516973004
Cr-Commit-Position: refs/heads/master@{#15168}
Previously, layout matrix was not correctly taken into account when calculating
the drawn size of the frame.
BUG=webrtc:6470
Review-Url: https://codereview.webrtc.org/2514793002
Cr-Commit-Position: refs/heads/master@{#15163}
In the AudioMixerImpl implementation, removing a source never fails
and the return value is always true (see audio_mixer/audio_mixer_impl.cc).
A return value of |false| signaled that removing a source failed for
some reason. We have come to the conclusion that
* we don't know how to handle a return value of |false|
* we can't think of why an alternative implementation would need to
signal failure when removing a stream.
To avoid having a status code that is never read, never acted upon and
probably never set to anything but |true|, we change ::RemoveSource to
not have a return value.
NOTRY=True
BUG=webrtc:6346
Review-Url: https://codereview.webrtc.org/2506173003
Cr-Commit-Position: refs/heads/master@{#15150}
Reason for revert:
The WebRtcBrowserTest.NegotiateUnsupportedVideoCodec test has been fixed in Chromium with the following change:
function removeVideoCodec(offerSdp) {
- offerSdp = offerSdp.replace('a=rtpmap:100 VP8/90000\r\n',
- 'a=rtpmap:100 XVP8/90000\r\n');
+ offerSdp = offerSdp.replace(/a=rtpmap:(\d+)\ VP8\/90000\r\n/,
+ 'a=rtpmap:$1 XVP8/90000\r\n');
return offerSdp;
}
Original issue's description:
> Revert of Stop using hardcoded payload types for video codecs (patchset #6 id:210001 of https://codereview.webrtc.org/2493133002/ )
>
> Reason for revert:
> Breaks chromium.fyi test:
> WebRtcBrowserTest.NegotiateUnsupportedVideoCodec
>
> Original issue's description:
> > Stop using hardcoded payload types for video codecs
> >
> > This CL stops using hardcoded payload types for different video codecs
> > and will dynamically assign them payload types incrementally from 96 to
> > 127 instead.
> >
> > This CL:
> > * Replaces 'std::vector<VideoCodec> DefaultVideoCodecList()' in
> > webrtcvideoengine2.cc with an explicit WebRtcVideoEncoderFactory for
> > internally supported software codecs instead. The purpose is to
> > streamline the payload type assignment in webrtcvideoengine2.cc which
> > will now have two encoder factories of the same
> > WebRtcVideoEncoderFactory type; one internal and one external.
> > * Removes webrtc::VideoEncoder::EncoderType and use cricket::VideoCodec
> > instead.
> > * Removes 'static VideoEncoder* Create(EncoderType codec_type)' and
> > moves the create function to the internal encoder factory instead.
> > * Removes video_encoder.cc. webrtc::VideoEncoder is now just an
> > interface without any static functions.
> > * The function GetSupportedCodecs in webrtcvideoengine2.cc unifies
> > the internal and external codecs and assigns them payload types
> > incrementally from 96 to 127.
> > * Updates webrtcvideoengine2_unittest.cc and removes assumptions about
> > what payload types will be used.
> >
> > BUG=webrtc:6677,webrtc:6705
> > R=hta@webrtc.org, ossu@webrtc.org, stefan@webrtc.org
> >
> > Committed: https://crrev.com/42043b95872b51321f508bf255d804ce3dff366b
> > Cr-Commit-Position: refs/heads/master@{#15135}
>
> TBR=hta@webrtc.org,stefan@webrtc.org,ossu@webrtc.org
> # Skipping CQ checks because original CL landed less than 1 days ago.
> NOPRESUBMIT=true
> NOTREECHECKS=true
> NOTRY=true
> BUG=webrtc:6677,webrtc:6705
>
> Committed: https://crrev.com/eacbaea920797ff751ca83050d140821f5055591
> Cr-Commit-Position: refs/heads/master@{#15140}
TBR=hta@webrtc.org,stefan@webrtc.org,ossu@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=webrtc:6677,webrtc:6705
Review-Url: https://codereview.webrtc.org/2511933002
Cr-Commit-Position: refs/heads/master@{#15148}
Payload type -> RtpCodecParameters maps added for sender and receiver.
This is a follow-up to https://codereview.webrtc.org/2484193002/ which
did the same thing for VideoMediaInfo. This information will be used to
produce RTCCodecStats[1].
Voice[Sender/Receiver]Info is updated with current codec payload type
for every stream which can be used to look up the codec in
VoiceMediaInfo.
[1] https://w3c.github.io/webrtc-stats/#codec-dict*
BUG=chromium:659117
Review-Url: https://codereview.webrtc.org/2503383002
Cr-Commit-Position: refs/heads/master@{#15144}
Added the callback in native c++ API.
The callback function is called when a track is added 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/2505173002
Cr-Commit-Position: refs/heads/master@{#15142}
Reason for revert:
Breaks chromium.fyi test:
WebRtcBrowserTest.NegotiateUnsupportedVideoCodec
Original issue's description:
> Stop using hardcoded payload types for video codecs
>
> This CL stops using hardcoded payload types for different video codecs
> and will dynamically assign them payload types incrementally from 96 to
> 127 instead.
>
> This CL:
> * Replaces 'std::vector<VideoCodec> DefaultVideoCodecList()' in
> webrtcvideoengine2.cc with an explicit WebRtcVideoEncoderFactory for
> internally supported software codecs instead. The purpose is to
> streamline the payload type assignment in webrtcvideoengine2.cc which
> will now have two encoder factories of the same
> WebRtcVideoEncoderFactory type; one internal and one external.
> * Removes webrtc::VideoEncoder::EncoderType and use cricket::VideoCodec
> instead.
> * Removes 'static VideoEncoder* Create(EncoderType codec_type)' and
> moves the create function to the internal encoder factory instead.
> * Removes video_encoder.cc. webrtc::VideoEncoder is now just an
> interface without any static functions.
> * The function GetSupportedCodecs in webrtcvideoengine2.cc unifies
> the internal and external codecs and assigns them payload types
> incrementally from 96 to 127.
> * Updates webrtcvideoengine2_unittest.cc and removes assumptions about
> what payload types will be used.
>
> BUG=webrtc:6677,webrtc:6705
> R=hta@webrtc.org, ossu@webrtc.org, stefan@webrtc.org
>
> Committed: https://crrev.com/42043b95872b51321f508bf255d804ce3dff366b
> Cr-Commit-Position: refs/heads/master@{#15135}
TBR=hta@webrtc.org,stefan@webrtc.org,ossu@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=webrtc:6677,webrtc:6705
Review-Url: https://codereview.webrtc.org/2513633002
Cr-Commit-Position: refs/heads/master@{#15140}