This CL does not make any functional changes. The purpose is to extract some common code that is needed for texture capture and texture encode.
This CL does the following changes:
* Move common EGL functions from org.webrtc.MediaCodecVideoDecoder to org.webrtc.EglBase.
* Move common GL functions from org.webrtc.VideoRendererGui to org.webrtc.GlUtil and org.webrtc.GlShader.
* Remove unused call to surfaceTexture.getTransformMatrix in YuvImageRenderer.
* Add helper functions rotatedWidth()/rotatedHeight() in VideoRenderer.I420Frame.
R=glaznev@webrtc.org, hbos@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/47309005.
Cr-Commit-Position: refs/heads/master@{#9414}
This makes some behaviorally-invariant changes to make certain code that
currently only works correctly with signed types work safely regardless of the
signedness of the types in question. This is preparation for a future change
that will convert a variety of types to size_t.
There are also some formatting changes (e.g. converting "enum hack" usage to real consts) to make it simpler to just change "int" to "size_t" in the future to change the types of those constants.
BUG=none
R=andrew@webrtc.org, juberti@webrtc.org, kwiberg@webrtc.org
TBR=ajm
Review URL: https://codereview.webrtc.org/1174813003
Cr-Commit-Position: refs/heads/master@{#9413}
This primarily addresses two things:
* Tab characters still present, mostly in comments
* printfs split across multiple lines in a suboptimal way
Along the way this fixes a few spelling errors and other minor changes.
BUG=none
R=kwiberg@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/52689004
Cr-Commit-Position: refs/heads/master@{#9406}
Per comments from HL/kwiberg on https://webrtc-codereview.appspot.com/42569004 , when there is existing usage of mixed types (int16_t, int, etc.), we'd prefer to standardize on larger types like int and phase out use of int16_t.
Specifically, "Using int16 just because we're sure all reasonable values will fit in 16 bits isn't usually meaningful in C."
This converts some existing uses of int16_t (and, in a few cases, other types such as uint16_t) to int (or, in a few places, int32_t). Other locations will be converted to size_t in a separate change.
BUG=none
R=andrew@webrtc.org, kwiberg@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/54629004
Cr-Commit-Position: refs/heads/master@{#9405}
(This reverts commit 3fbf3f8841b5460503fb646eaedcb063620434a8.)
The original submission was reverted because it broke the Chrome build. This is fixed in patch set 2 of this change by keeping the old MediaConstraintsInterface string kExperimentalEchoCancellation. It will be removed once the Chrome code has been updated.
Original description:
"We use this Config struct for enabling/disabling Extended filter mode in AEC. This change renames it to ExtendedFilter for readability reasons. The corresponding media constraint is also renamed to kExtendedFilterEchoCancellation.
The old Config is kept in parallel with the new during a transition period. This is to avoid problems with API breakages. During this period, if any of the two Configs are enabled, the extended filter mode is engaged in APM. That is, the two Configs are combined with an "OR" operation.
This change also renames experimental_aec in AudioOptions to extended_filter_aec."
BUG=webrtc:4696
R=bjornv@webrtc.org, tommi@webrtc.org
Review URL: https://codereview.webrtc.org/1151573021.
Cr-Commit-Position: refs/heads/master@{#9401}
Packet-loss computation and plot were added to BweReceiver class.
Objective function and plot were added to PacketReceiver class.
BUG=4550
R=stefan@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/56459004
Cr-Commit-Position: refs/heads/master@{#9391}
If the buffer becomes full an OnPacketReady callback will be used to
send the packets created so far. On success the buffer can be reused.
The same callback will be called when the last packet has beed created.
Also made some changes to RawPacket. Buffer will now be heap-allocated
rather than (potentially) stack-allocated, but on the plus side it can
now be allocted with variable size and also avoids one memcpy.
BUG=
patch from issue 56429004 at patchset 160001 (http://crrev.com/56429004#ps160001)
R=asapersson@webrtc.org
Review URL: https://codereview.webrtc.org/1165113002
Cr-Commit-Position: refs/heads/master@{#9390}
timestamp_ is only used in GenerateFrame() and its old value is
discarded. So it just needs to be a local variable in GenerateFrame().
As a result, we can remove the start_timestamp parameter from the
constructor and Init().
Also mark the GeneratePacket() method private because it is only used
internally.
R=stefan@webrtc.org
BUG=none
TEST=none
Review URL: https://webrtc-codereview.appspot.com/50149004
Cr-Commit-Position: refs/heads/master@{#9386}
Verifies that reduced-size isn't configured in WebRtcVideoEngine2
without explicit configuration (which doesn't exist). Also disables REMB
in the default config because it requires reconfiguration.
Adds default-config tests to make sure that they don't contain
parameters that need to be negotiated between clients.
BUG=chromium:497103, webrtc:4745
R=mflodman@webrtc.org, stefan@webrtc.org
Review URL: https://codereview.webrtc.org/1171533002
Cr-Commit-Position: refs/heads/master@{#9384}
We use this Config struct for enabling/disabling Extended filter mode
in AEC. This change renames it to ExtendedFilter for readability
reasons. The corresponding media constraint is also renamed to
kExtendedFilterEchoCancellation.
The old Config is kept in parallel with the new during a transition
period. This is to avoid problems with API breakages. During this
period, if any of the two Configs are enabled, the extended filter
mode is engaged in APM. That is, the two Configs are combined with an
"OR" operation.
This change also renames experimental_aec in AudioOptions to extended_filter_aec.
BUG=4696
R=bjornv@webrtc.org, tommi@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/54659004
Cr-Commit-Position: refs/heads/master@{#9378}
The delay agnostic AEC uses a signal based delay correction method to adjust buffer synchronization between loudspeaker and microphone. On Mac in particular we have seen deviations in UMA stats that point towards an echo already at startup. This is likely due to an early and incorrect correction based on poor audio data.
By waiting 15 seconds before we turn on the ability to correct we can avoid a majority of these.
The reported delay values are in general accurate enough and relying on them in the beginning is fine. The value 15 seconds is chosen because we have seen from UMA data that a significant amount of calls tend to end before 15 seconds when being in the UseDelayAgnosticAEC Finch experiment.
We turn this "feature" on for all platforms but Android, where the reported system delays are inaccurate and we want to take action as soon as possible.
In addition, the set of "good" delay values has been increased from 25% to 75% of the filter length.
BUG=webrtc:3504
R=henrik.lundin@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/50199004
Cr-Commit-Position: refs/heads/master@{#9376}