The code that depends on the reverted CL is disabled but not removed. NativeHandleImpl is reverted to the previous implementation, and the new implementation is renamed to NativeTextureHandleImpl. Texture capture can not be used anymore, because it will crash in peerconnection_jni.cc.
Reason for revert:
Increased HW decoder latency and crashes related to that. Also suspected cause of video tearing.
Original issue's description:
> This CL should be the last one in a series to finally
> unblock camera texture capture.
>
> The SurfaceTexture.updateTexImage() calls are moved from
> the video renderers into MediaCodecVideoDecoder, and the
> destructor of the texture frames will signal
> MediaCodecVideoDecoder that the frame has returned. This
> CL also removes the SurfaceTexture from the native handle
> and only exposes the texture matrix instead, because only
> the video source should access the SurfaceTexture.
>
> BUG=webrtc:4993
> R=glaznev@webrtc.org, perkj@webrtc.org
>
> Committed: https://crrev.com/91b348c7029d843e06868ed12b728a809c53176c
> Cr-Commit-Position: refs/heads/master@{#10203}
TBR=glaznev
BUG=webrtc:4993
Review URL: https://codereview.webrtc.org/1394103005
Cr-Commit-Position: refs/heads/master@{#10288}
Landmines is a feature used in Chromium that makes it possible to
clobber the build output directory when needed. Example scenarios
are when compiler/tool/infrastructure changes require a full rebuild.
This is mainly to ease clobbering on all bots, but will also ensure
developers don't have to waste time on figuring out what's wrong
(or rely on reading PSA e-mails announcing when such manual action
is required).
This CL depends on https://codereview.chromium.org/1407733002/
being landed and rolled into DEPS first.
BUG=5077
R=kjellander@chromium.org, machenbach@chromium.org
Review URL: https://codereview.webrtc.org/1402923003 .
Cr-Commit-Position: refs/heads/master@{#10287}
Encoders need to be externally provided. To use software encoders they
need to be created and registered from the outside.
BUG=webrtc:1695
R=stefan@webrtc.org
Review URL: https://codereview.webrtc.org/1394823002 .
Cr-Commit-Position: refs/heads/master@{#10283}
After the TransportController CL, BaseSession does little more than
hold a state and an error, and act as an intermediary for the
TransportController. So it doesn't make sense for it to be its own
class.
Review URL: https://codereview.webrtc.org/1397973002
Cr-Commit-Position: refs/heads/master@{#10281}
Also parameterise on PeerConnectionParameters to prepare for more test variations. (capture and encode to textures)
Review URL: https://codereview.webrtc.org/1404093002
Cr-Commit-Position: refs/heads/master@{#10279}
Reason for reland:
The original CL actually didn't break browser_tests; it was
just a coincidence that it started failing.
Original issue's description:
> Revert of Moving MediaStreamSignaling logic into PeerConnection. (patchset #10 id:180001 of https://codereview.webrtc.org/1393563002/ )
>
> Reason for revert:
> Broke browser_tests on Mac. Still need to investigate the cause.
>
> Original issue's description:
> > Moving MediaStreamSignaling logic into PeerConnection.
> >
> > This needs to happen because in the future, m-lines will be offered
> > based on the set of RtpSenders/RtpReceivers, rather than the set of
> > tracks that MediaStreamSignaling knows about.
> >
> > Besides that, MediaStreamSignaling was a "glue class" without
> > a clearly defined role, so it going away is good for other
> > reasons as well.
> >
> > Committed: https://crrev.com/97c392935411398b506861601c82e31d95c591f0
> > Cr-Commit-Position: refs/heads/master@{#10268}
>
> TBR=pthatcher@webrtc.org
> NOPRESUBMIT=true
> NOTREECHECKS=true
> NOTRY=true
>
> Committed: https://crrev.com/fc648b6d934e936f4d9a32c813364b331536ec3b
> Cr-Commit-Position: refs/heads/master@{#10269}
TBR=pthatcher@webrtc.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
Review URL: https://codereview.webrtc.org/1404473005
Cr-Commit-Position: refs/heads/master@{#10277}
Also updated the RTPPayloadRegistry::RestoreOriginalPacket signature to not take the first arg as a **, since it isn't modified.
Review URL: https://codereview.webrtc.org/1394573004
Cr-Commit-Position: refs/heads/master@{#10276}
This CL should reduce the number of timeouts for dequeueInputBuffer() which results in the log "MediaCodecVideo: dequeueInputBuffer error" followed by software fallback for VP8/VP9 and codec restart for H264.
A timeout always happen for dequeueInputBuffer() when frames_received_ > frames_decoded_ + num_input_buffers. The following code tries to drain the decoder before enqueuing more input buffers:
// Try to drain the decoder and wait until output is not too
// much behind the input.
if (frames_received_ > frames_decoded_ + max_pending_frames_) {
ALOGV("Received: %d. Decoded: %d. Wait for output...",
frames_received_, frames_decoded_);
if (!DeliverPendingOutputs(jni, kMediaCodecTimeoutMs,
true /* dropFrames */)) {
ALOGE << "DeliverPendingOutputs error";
return ProcessHWErrorOnCodecThread();
}
if (frames_received_ > frames_decoded_ + max_pending_frames_) {
ALOGE << "Output buffer dequeue timeout";
return ProcessHWErrorOnCodecThread();
}
...
}
However, for H264, |max_pending_frames_| can currently be larger than the number of input buffers so that the code above is never executed. This CL limits |max_pending_frames_| to the number of input buffers.
TBR=glaznev
BUG=b/24867188,b/24864151
Review URL: https://codereview.webrtc.org/1394303005
Cr-Commit-Position: refs/heads/master@{#10273}
This is no longer used. Related code in the iSAC codec itself will be
deleted a follow-up CL.
BUG=4210
Review URL: https://codereview.webrtc.org/1404463003
Cr-Commit-Position: refs/heads/master@{#10272}
Due to https://codereview.chromium.org/1397493004 we're now adding
a build_overrides directory in WebRTC. Thanks to this, we no longer
need to pass --args="build_with_chromium=false" when running GN in
standalone WebRTC.
Change log: c089d37..159828f
Full diff: c089d37..159828f
No dependencies changed.
No update to Clang.
BUG=webrtc:5070,chromium:541791
TBR=tommi@webrtc.org
CQ_EXTRA_TRYBOTS=tryserver.webrtc:win_baremetal,mac_baremetal,linux_baremetal
Review URL: https://codereview.webrtc.org/1403453003 .
Cr-Commit-Position: refs/heads/master@{#10270}
Reason for revert:
Broke browser_tests on Mac. Still need to investigate the cause.
Original issue's description:
> Moving MediaStreamSignaling logic into PeerConnection.
>
> This needs to happen because in the future, m-lines will be offered
> based on the set of RtpSenders/RtpReceivers, rather than the set of
> tracks that MediaStreamSignaling knows about.
>
> Besides that, MediaStreamSignaling was a "glue class" without
> a clearly defined role, so it going away is good for other
> reasons as well.
>
> Committed: https://crrev.com/97c392935411398b506861601c82e31d95c591f0
> Cr-Commit-Position: refs/heads/master@{#10268}
TBR=pthatcher@webrtc.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
Review URL: https://codereview.webrtc.org/1403633005
Cr-Commit-Position: refs/heads/master@{#10269}
This needs to happen because in the future, m-lines will be offered
based on the set of RtpSenders/RtpReceivers, rather than the set of
tracks that MediaStreamSignaling knows about.
Besides that, MediaStreamSignaling was a "glue class" without
a clearly defined role, so it going away is good for other
reasons as well.
Review URL: https://codereview.webrtc.org/1393563002
Cr-Commit-Position: refs/heads/master@{#10268}
SurfaceViewHelper requires EGL14 that was added in API level 17. Since the SurfaceViewHelper is only neeed when we capture to textures, this cl change back to not use it when we are capturing to byte buffers.
Also, thread.quitsafely was added in level 18. Instead a new ThreadUtil method has been added for this.
BUG=b/24782220
TEST = run
ninja -C out/Debug libjingle_peerconnection_android_unittest && CHECKOUT_SOURCE_ROOT=`pwd` build/android/adb_install_apk.py --debug out/Debug/apks/libjingle_peerconnection_android_unittest.apk && ./third_party/android_tools/sdk/platform-tools/adb shell am instrument -w -e class org.webrtc.VideoCapturerAndroidTest org.webrtc.test/android.test.InstrumentationTestRunner on a device running Android 4.1 (I tried Nexus 7, the first version)
Review URL: https://codereview.webrtc.org/1401023003
Cr-Commit-Position: refs/heads/master@{#10265}
This is no longer used. Related code in NetEq and the iSAC codec itself
will be deleted in follow-up CLs.
BUG=4210
Review URL: https://codereview.webrtc.org/1404623002
Cr-Commit-Position: refs/heads/master@{#10264}
This CL makes AddRef() and Release() const member methods and the refcount integer mutable. This is reasonable, because they only manage the lifetime of the object, and this is also how it's done in Chromium.
The purpose is to be able to capture a const pointer in a scoped_refptr, which is currenty impossible. The practial problem this CL solves is this:
void Foo::Bar() const {}
rtc::Callback0<void> Foo::MakeClosure() const {
return rtc::Bind(&Foo::Bar, this);
}
We currently capture |this| as const Foo*. With this CL, |this| will be captured as scoped_refptr<const Foo>.
A test is also added in bind_unittest to check this behaviour.
BUG=webrtc:5065
R=perkj@webrtc.org, tommi@webrtc.org
Review URL: https://codereview.webrtc.org/1403683004 .
Cr-Commit-Position: refs/heads/master@{#10253}
Reason for revert:
Temporarily reverting as this causes some issues with perf tests. Especially tests with packet loss no longer works.
Original issue's description:
> Adding support for simulcast and spatial layers into VideoQualityTest
>
> The CL includes several changes:
> - Adding flags describing the streams and spatial layers.
> - Reorganizing the order of the flags, to make them easier to maintain.
> - Adding a member .params_ to VideoQualityAnalyzer.
> (instead of passing it to every member function manually)
> - Updating VideoAnalyzer to support simulcast.
> (select appropriate ssrc and fix timestamps which are sometimes increased by 1)
> - VP9EncoderImpl already had code for automatic calculation of bitrate for each layer.
> Changing to first read bitrates and resolution ratios from the flags, if specified.
> If not specified, reverting to the old code are setting the values automatically.
> - Changing the parameters in LayerFilteringTransport, replacing
> xx_discard_thresholds with selected_xx, to make it easier to use for the end user.
>
> Committed: https://crrev.com/87f83a9a27d657731ccb54025bc04ccad0da136e
> Cr-Commit-Position: refs/heads/master@{#10215}
TBR=pbos@webrtc.org,mflodman@webrtc.org,ivica@webrtc.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
Review URL: https://codereview.webrtc.org/1397363002
Cr-Commit-Position: refs/heads/master@{#10252}
This make small refactorings to MediaVideoEncoder to prepare for adding support to encode from textures. The C++ layer does not have any functional changes.
- Moves ResetEncoder to always work on the codec thread
- Adds use of ThreadChecker.
- Change Java MediaEncoder.Init to return true or false and introduce method getInputBuffers.
- Add simple unit test for Java MediaCodecVideoEncoder.
BUG=webrtc:4993
Review URL: https://codereview.webrtc.org/1396073003
Cr-Commit-Position: refs/heads/master@{#10250}