Reason for revert:
Create reland CL to add fix to.
Original issue's description:
> Revert of Add a flags field to video timing extension. (patchset #15 id:280001 of https://codereview.webrtc.org/3000753002/ )
>
> Reason for revert:
> Speculative revet for breaking remoting_unittests in fyi bots.
> https://build.chromium.org/p/chromium.webrtc.fyi/waterfall?builder=Win7%20Tester
>
> Original issue's description:
> > Add a flags field to video timing extension.
> >
> > The rtp header extension for video timing shuold have an additional
> > field for signaling metadata, such as what triggered the extension for
> > this particular frame. This will allow separating frames select because
> > of outlier sizes from regular frames, for more accurate stats.
> >
> > This implementation is backwards compatible in that it can read video
> > timing extensions without the new flag field, but it always sends with
> > it included.
> >
> > BUG=webrtc:7594
> >
> > Review-Url: https://codereview.webrtc.org/3000753002
> > Cr-Commit-Position: refs/heads/master@{#19353}
> > Committed: cf5d485e14
>
> TBR=danilchap@webrtc.org,kthelgason@webrtc.org,stefan@webrtc.org,sprang@webrtc.org
> # Skipping CQ checks because original CL landed less than 1 days ago.
> NOPRESUBMIT=true
> NOTREECHECKS=true
> NOTRY=true
> BUG=webrtc:7594
>
> Review-Url: https://codereview.webrtc.org/2995953002
> Cr-Commit-Position: refs/heads/master@{#19360}
> Committed: f0f7378b05TBR=danilchap@webrtc.org,kthelgason@webrtc.org,stefan@webrtc.org,emircan@google.com
# Not skipping CQ checks because original CL landed more than 1 days ago.
BUG=webrtc:7594
Review-Url: https://codereview.webrtc.org/2996153002
Cr-Commit-Position: refs/heads/master@{#19405}
We are already asserting in tryDeliverTextureFrame() that we are on the
SurfaceTextureHelper handler thread, but this behavior isn't guaranteed
by Android.
Also updated docs for OnTextureFrameAvailableListener, since other
classes (e.g. capturers) were also asserting that they were called on
the SurfaceTextureHelper thread.
Bug: webrtc:8087, b/64609528
Change-Id: I47148c452f66f24477e438b06ef124a96965853d
Reviewed-on: https://chromium-review.googlesource.com/610495
Reviewed-by: Sami Kalliomäki <sakal@webrtc.org>
Commit-Queue: Jonathan Yu <yujo@chromium.org>
Cr-Commit-Position: refs/heads/master@{#19398}
Reason for revert:
Speculative revet for breaking remoting_unittests in fyi bots.
https://build.chromium.org/p/chromium.webrtc.fyi/waterfall?builder=Win7%20Tester
Original issue's description:
> Add a flags field to video timing extension.
>
> The rtp header extension for video timing shuold have an additional
> field for signaling metadata, such as what triggered the extension for
> this particular frame. This will allow separating frames select because
> of outlier sizes from regular frames, for more accurate stats.
>
> This implementation is backwards compatible in that it can read video
> timing extensions without the new flag field, but it always sends with
> it included.
>
> BUG=webrtc:7594
>
> Review-Url: https://codereview.webrtc.org/3000753002
> Cr-Commit-Position: refs/heads/master@{#19353}
> Committed: cf5d485e14TBR=danilchap@webrtc.org,kthelgason@webrtc.org,stefan@webrtc.org,sprang@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=webrtc:7594
Review-Url: https://codereview.webrtc.org/2995953002
Cr-Commit-Position: refs/heads/master@{#19360}
The rtp header extension for video timing shuold have an additional
field for signaling metadata, such as what triggered the extension for
this particular frame. This will allow separating frames select because
of outlier sizes from regular frames, for more accurate stats.
This implementation is backwards compatible in that it can read video
timing extensions without the new flag field, but it always sends with
it included.
BUG=webrtc:7594
Review-Url: https://codereview.webrtc.org/3000753002
Cr-Commit-Position: refs/heads/master@{#19353}
VideoSinks receive the new kind of VideoFrames and will replace
VideoRenderers. Converting from old texture frames to VideoFrames will
involve conversion to I420 so it is not recommended to use VideoSinks
before all sources produce VideoFrames.
BUG=webrtc:7749, webrtc:7760
Review-Url: https://codereview.webrtc.org/3002553002
Cr-Commit-Position: refs/heads/master@{#19335}
This has been a frequent source of confusion, especially since the
method names don't match anything in the standard exactly.
BUG=None
NOTRY=True
Review-Url: https://codereview.webrtc.org/2994733002
Cr-Commit-Position: refs/heads/master@{#19290}
Relanding after adding "androidnetworkmonitor_jni.h" header to jni/
directory, since some clients were including it directly.
This CL breaks peerconnection_jni.cc apart, into one file for each
class. It also moves the methods for converting between C++/Java
structs into "java_native_conversion.cc", and uses a consistent naming
scheme ("JavaToNativeX, NativeToJavaX"). These files go into a new
"pc" directory, of which deadbeef@ is added as an owner.
It also moves some relevant files to the "pc" directory that belong
there: ownedfactoryandthreads, androidnetworkmonitor_jni, and
rtcstatscollectorcallbackwrapper. This directory is intended to hold
all the files that deal with the PeerConnection API specifically, or
related classes (like DataChannel, RtpSender, MediaStreamTrack) that
are tied to it closely.
BUG=webrtc:8055
Review-Url: https://codereview.webrtc.org/2992103002
Cr-Commit-Position: refs/heads/master@{#19241}
Reason for revert:
Borken in the internal projects.
Original issue's description:
> Break peerconnection_jni.cc into multiple files, in "pc" directory.
>
> This CL breaks peerconnection_jni.cc apart, into one file for each
> class. It also moves the methods for converting between C++/Java
> structs into "java_native_conversion.cc", and uses a consistent naming
> scheme ("JavaToNativeX, NativeToJavaX"). These files go into a new
> "pc" directory, of which deadbeef@ is added as an owner.
>
> It also moves some relevant files to the "pc" directory that belong
> there: ownedfactoryandthreads, androidnetworkmonitor_jni, and
> rtcstatscollectorcallbackwrapper. This directory is intended to hold
> all the files that deal with the PeerConnection API specifically, or
> related classes (like DataChannel, RtpSender, MediaStreamTrack) that
> are tied to it closely.
>
> deadbeef@webrtc.org is added as an owner of the new "pc" subdirectory.
>
> BUG=webrtc:8055
>
> Review-Url: https://codereview.webrtc.org/2992103002
> Cr-Commit-Position: refs/heads/master@{#19223}
> Committed: dd7d8f1b60TBR=magjed@webrtc.org,sakal@webrtc.org,deadbeef@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=webrtc:8055
Review-Url: https://codereview.webrtc.org/2989323002
Cr-Commit-Position: refs/heads/master@{#19226}
This CL breaks peerconnection_jni.cc apart, into one file for each
class. It also moves the methods for converting between C++/Java
structs into "java_native_conversion.cc", and uses a consistent naming
scheme ("JavaToNativeX, NativeToJavaX"). These files go into a new
"pc" directory, of which deadbeef@ is added as an owner.
It also moves some relevant files to the "pc" directory that belong
there: ownedfactoryandthreads, androidnetworkmonitor_jni, and
rtcstatscollectorcallbackwrapper. This directory is intended to hold
all the files that deal with the PeerConnection API specifically, or
related classes (like DataChannel, RtpSender, MediaStreamTrack) that
are tied to it closely.
deadbeef@webrtc.org is added as an owner of the new "pc" subdirectory.
BUG=webrtc:8055
Review-Url: https://codereview.webrtc.org/2992103002
Cr-Commit-Position: refs/heads/master@{#19223}
Previously, the matrix in VideoFrame was used to crop and scale the
frame. This caused complications because webrtc::VideoFrame doesn't
include a matrix. cropAndScale method is added to VideoBuffer class for
cropping and scaling instead.
BUG=webrtc:7749, webrtc:7760
Review-Url: https://codereview.webrtc.org/2990583002
Cr-Commit-Position: refs/heads/master@{#19179}
When you create multiple "PeerConnectionFactory"s, they end up using
the same NetworkMonitor singleton. But the second one's
"AndroidNetworkMonitor" class (in C++) wasn't getting the expected
network list update, and as a result it wasn't binding sockets to
networks successfully, acting as if the networks didn't exist.
The solution is just to move "updateActiveNetworkList" to
"startMonitoring". This CL also does some other minor
cleanup/refactoring, and fixes a more corner-casey issue where, if the
first PeerConnection is destroyed, the second one would stop receiving
network updates.
BUG=webrtc:7946
Review-Url: https://codereview.webrtc.org/2990693002
Cr-Commit-Position: refs/heads/master@{#19156}
All downstream code have been updated to the new location.
In PRESUBMIT.py:
* Remove webrtc/rtc_base from CPP_BLACKLIST
* Add webrtc/rtc_base to LEGACY_API_DIRS
Fix some duplicated paths in
webrtc/modules/audio_processing/test/conversational_speech/BUILD.gn
BUG=webrtc:7634
TBR=kwiberg@webrtc.org
Review-Url: https://codereview.webrtc.org/2976293002
Cr-Commit-Position: refs/heads/master@{#19094}
HardwareVideoEncoderFactory can now take an EglBase.Context on creation.
When it does, it creates video encoders in texture mode. It uses the
COLOR_FormatSurface colorFormat. It passes the EglBase.Context to the
HardwareVideoEncoder.
The HardwareVideoEncoder sets up an input surface for its codec and handles
incoming frames by drawing them onto the input surface.
BUG=webrtc:7760
R=pthatcher@webrtc.org, sakal@webrtc.org
Review-Url: https://codereview.webrtc.org/2977153003 .
Cr-Commit-Position: refs/heads/master@{#19083}
HardwareVideoDecoder is now a listener for SurfaceTextureHelper. It takes a
SurfaceTextureHelper on construction. If it is non-null, it operates in texture
mode instead of byte-buffer mode.
When in texture mode, the HardwareVideoDecoder renders output frames to a Surface,
listens for the texture frame to become available, wraps it in a VideoFrame, and
pushes it to the decoder callback.
As in MediaCodecVideoDecoder, it may queue up to three buffers while waiting for
the surface to become available for rendering. If more buffers are queued, it will
drop the oldest.
This change also implements the VideoFrame.TextureBuffer and reorganizes code
for wrapping an existing ByteBuffer into an I420Buffer. This makes it easier
to implement the texture buffer's ToI420() method.
BUG=webrtc:7760
R=pthatcher@webrtc.org, sakal@webrtc.org
Review-Url: https://codereview.webrtc.org/2977643002 .
Cr-Commit-Position: refs/heads/master@{#19081}
The surface view renderer size was set to match parent so it couldn't
adjust based on the frame size. The size is now set to wrap_content
which allows the renderer to adjust. The root element of the call
activity is changed to FrameLayout to allow the renderer to center.
requestLayout is added to SurfaceView setScalingType so onMeasure gets
called again.
BUG=webrtc:7901
Review-Url: https://codereview.webrtc.org/2978173002
Cr-Commit-Position: refs/heads/master@{#19073}
Bug: webrtc:7969
Change-Id: I3fbb723d35fa6cc4c7b92aa1e155b974e9fb0b55
Reviewed-on: https://chromium-review.googlesource.com/567698
Commit-Queue: Steve Anton <steveanton@webrtc.org>
Reviewed-by: Tommi <tommi@webrtc.org>
Reviewed-by: Alex Glaznev <glaznev@chromium.org>
Reviewed-by: Peter Thatcher <pthatcher@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#19062}
This is a partial re-land. The change doesn't make the default Thread ctor protected anymore but it does mark it as deprecated and updates all use of it in WebRTC.
Original issue's description:
Make the default ctor of rtc::Thread, protected.
The goal is to force use of Thread::Create or Thread::CreateWithSocketServer.
The default constructor constructs a 'default' socket server, which is usually a 'physical' socket server, but not always. Not every instance of Thread actually needs to have network support, so it's better to have this be explicit instead of unknowingly instantiate one.
BUG=none
Review-Url: https://codereview.webrtc.org/2977953002
Cr-Commit-Position: refs/heads/master@{#19031}
If a SurfaceViewRenderer is reinitialized, the onFirstFrameRendered
callback is not fired.
Ensure that we reset the flag when the SurfaceViewRenderer is
initialized.
BUG=webrtc:7985
Review-Url: https://codereview.webrtc.org/2981793002
Cr-Commit-Position: refs/heads/master@{#19016}
Reason for revert:
Break projects.
Original issue's description:
> Make the default ctor of rtc::Thread, protected.
> The goal is to force use of Thread::Create or Thread::CreateWithSocketServer.
>
> The default constructor constructs a 'default' socket server, which is usually a 'physical' socket server, but not always. Not every instance of Thread actually needs to have network support, so it's better to have this be explicit instead of unknowingly instantiate one.
>
> BUG=none
>
> Review-Url: https://codereview.webrtc.org/2981623002
> Cr-Commit-Position: refs/heads/master@{#19001}
> Committed: a8a3515997TBR=kthelgason@webrtc.org,tommi@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=none
Review-Url: https://codereview.webrtc.org/2979963002
Cr-Commit-Position: refs/heads/master@{#19003}
The goal is to force use of Thread::Create or Thread::CreateWithSocketServer.
The default constructor constructs a 'default' socket server, which is usually a 'physical' socket server, but not always. Not every instance of Thread actually needs to have network support, so it's better to have this be explicit instead of unknowingly instantiate one.
BUG=none
Review-Url: https://codereview.webrtc.org/2981623002
Cr-Commit-Position: refs/heads/master@{#19001}
Suppressing lint errors using comments is an undocumented feature of the
linter, and suppressing using the tools:ignore attribute should be
preferred.
Suppressing using comments becomes a problem when using the manifest
merger introduced in
6ada47bc79
as it reformats the comments slightly:
<!--suppress MissingPrefix -->
becomes
<!-- supress MissingPrefix -->
which causes the linter to disregard the suppression.
Bug: 740657
Change-Id: I8e365744d089271c390254e7c958b24b81043766
Reviewed-on: https://chromium-review.googlesource.com/566860
Reviewed-by: Magnus Jedvert <magjed@webrtc.org>
Commit-Queue: Ingemar Ådahl <ingemara@opera.com>
Cr-Commit-Position: refs/heads/master@{#18971}
All downstream code have been updated to the new location.
In PRESUBMIT.py:
* Remove webrtc/rtc_base from CPP_BLACKLIST
* Add webrtc/rtc_base to LEGACY_API_DIRS
Fix some duplicated paths in
webrtc/modules/audio_processing/test/conversational_speech/BUILD.gn
BUG=webrtc:7634
TBR=kwiberg@webrtc.org
Review-Url: https://codereview.webrtc.org/2973183002
Cr-Commit-Position: refs/heads/master@{#18948}
I used a command like this to update the paths:
perl -pi -e "s/webrtc\/base/webrtc\/rtc_base/g" `find webrtc/rtc_base -name "*.cc" -o -name "*.h"`
BUG=webrtc:7634
NOPRESUBMIT=True # cpplint errors that aren't caused by this CL.
Review-Url: https://codereview.webrtc.org/2969623003
Cr-Commit-Position: refs/heads/master@{#18870}
[This CL is a rebase of an original CL by solenberg@:
https://codereview.webrtc.org/2948763002/ which in turn was a
rebase of an original CL by peah@:
https://chromium-review.googlesource.com/c/527032/]
Allow an external audio processing module to be used in WebRTC
This CL adds support for optionally using an externally created audio
processing module in a peerconnection. The ownership is shared
between the peerconnection and the external creator of the module.
As part of this the internal ownership of the audio processing module
is moved from VoiceEngine to WebRtcVoiceEngine.
BUG=webrtc:7775
Review-Url: https://codereview.webrtc.org/2961723004
Cr-Commit-Position: refs/heads/master@{#18837}
In most cases we can just return a frame referencing the buffer
returned by the decoder.
Bug: webrtc:7760
Change-Id: I0b42ab9662b39149e42a3c83adfd38a9d80e0e30
Reviewed-on: https://chromium-review.googlesource.com/544299
Commit-Queue: Sami Kalliomäki <sakal@webrtc.org>
Reviewed-by: Bjorn Mellem <mellem@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#18824}
Reland the base->rtc_base without adding stub headers (will be
done in follow-up CL). This preserves git blame history of all files.
BUG=webrtc:7634
NOTRY=True
TBR=kwiberg@webrtc.org
Change-Id: Iea3bb6f3f67b8374c96337b63e8f5aa3e6181012
Reviewed-on: https://chromium-review.googlesource.com/554611
Reviewed-by: Henrik Kjellander <kjellander@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#18821}
Will reland in two different commits to preserve git blame history.
BUG=webrtc:7634
NOTRY=True
TBR=kwiberg@webrtc.org
Change-Id: I550da8525aeb9c5b8f96338fcf1c9714f3dcdab1
Reviewed-on: https://chromium-review.googlesource.com/554610
Reviewed-by: Henrik Kjellander <kjellander@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#18820}