We knew that we should not update buffer level during DTX period. We already fulfill this upon no packet receipt. But we missed doing it for DTX-signaling packets. This CL is to fix that.
Bug: b/129521878
Change-Id: I72ca18e3b21e956123fe6e3119ef0d7c981c9eec
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/133183
Commit-Queue: Minyue Li <minyue@webrtc.org>
Reviewed-by: Jakob Ivarsson <jakobi@webrtc.org>
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27643}
Semi-automatically created with:
git grep -l " testing::" | xargs sed -i "s/ testing::/ ::testing::/g"
git grep -l "(testing::" | xargs sed -i "s/(testing::/(::testing::/g"
git cl format
After this, two .cc files failed to compile and I have fixed them
manually.
Bug: webrtc:10523
Change-Id: I4741d3bcedc831b6c5fdc04485678617eb4ce031
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/132018
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27526}
See https://webrtc-review.googlesource.com/c/src/+/121764 for the
overall vision.
This CL adds a multistream Opus decoder. It's a new code-path to not
interfere with the standard Opus decoder. We introduce new SDP syntax,
which uses terminology of RFC 7845. We also set up the decoder side to
parse it. The encoder part will come in a later CL.
E.g. this is the new SDP syntax for 6.1 surround sound:
"multiopus/48000/6 channel_mapping=0,4,1,2,3,5 num_streams=4 coupled_streams=2"
Bug: webrtc:8649
Change-Id: Ifbc584cbb6d07aed373f223512a20d6d72cec5ec
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/129768
Commit-Queue: Alex Loiko <aleloi@webrtc.org>
Reviewed-by: Oskar Sundbom <ossu@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27493}
Switch to explicit channel mappings (RFC 7845) when creating
multi-stream Opus en/de-coders. The responsibility of setting up the
channel mappings will shift from WebRTC to the WebRTC user.
See https://webrtc-review.googlesource.com/c/src/+/121764 for the
current vision. See also the first child CL
https://webrtc-review.googlesource.com/c/src/+/129768
that sets up the Decoder to use this code.
Bug: webrtc:8649
Change-Id: I55959a293d54bb4c982eff68ec107c5ef8666c5c
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/129767
Commit-Queue: Alex Loiko <aleloi@webrtc.org>
Reviewed-by: Oskar Sundbom <ossu@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27452}
Currently the code in NetEqTestFactory will crash when something
unexpected happens. It would be better to return a nullptr instead and
let the caller decide how to proceed.
Bug: webrtc:10337
Change-Id: I3cfdffa7e6f2016eeaa5d6e80c5dd6c954ef8485
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/127894
Reviewed-by: Pablo Barrera González <barrerap@webrtc.org>
Commit-Queue: Ivo Creusen <ivoc@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27226}
Previously only reading from the filesystem was supported, this CL
allows parsing an event log from a string.
Bug: webrtc:10337
Change-Id: Iadde3319eb8fb4175625f510201fac9c01c80ed9
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/127296
Commit-Queue: Ivo Creusen <ivoc@webrtc.org>
Reviewed-by: Minyue Li <minyue@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27202}
When we offset the measured inter-arrival time due to packet loss, it will sometimes be less than zero. This is the correct value to use when calculating the relative packet arrival delay.
Bug: webrtc:10333
Change-Id: I14a68563a379fa0b9444684304362503a6f1bfca
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/127547
Reviewed-by: Minyue Li <minyue@webrtc.org>
Commit-Queue: Jakob Ivarsson <jakobi@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27164}
This reverts commit c4b391a257.
Reason for revert: issue fixed
Original change's description:
> Revert "NetEQ RTP Play: Optionally write output audio file"
>
> This reverts commit 6330818ec8.
>
> Reason for revert: This breaks api/test/neteq_simulator_factory.cc, which unfortunately was not caught by our bots.
>
> Original change's description:
> > NetEQ RTP Play: Optionally write output audio file
> >
> > This CL makes the output audio file optional to more
> > quickly run neteq_rtpplay when no audio output is needed.
> > The CL also includes necessary adaptations because of pre-existing
> > dependencies (e.g., the output audio file name is used to create
> > the plotting script file names).
> >
> > The command line arguments are retro-compatible - i.e., same behavior
> > when specifying the output audio file and the new flag
> > --output_files_base_name is not used.
> >
> > This CL also includes a test script with which the retro-compatibility
> > has been verified.
> >
> > Bug: webrtc:10337
> > Change-Id: Ie3f301b3b2ed0682fb74426d9cf452396f2b112b
> > Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/126224
> > Commit-Queue: Alessio Bazzica <alessiob@webrtc.org>
> > Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
> > Cr-Commit-Position: refs/heads/master@{#27067}
>
> TBR=henrik.lundin@webrtc.org,alessiob@webrtc.org,ivoc@webrtc.org
>
> Change-Id: I0c63a8ba9566ef567ee398f571f2a511916fa742
> No-Presubmit: true
> No-Tree-Checks: true
> No-Try: true
> Bug: webrtc:10337
> Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/127293
> Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
> Commit-Queue: Ivo Creusen <ivoc@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#27078}
TBR=henrik.lundin@webrtc.org,alessiob@webrtc.org,ivoc@webrtc.org
Change-Id: Ia7061f7c2d69db61638ad612e82cd429eb49d539
Bug: webrtc:10337
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/127540
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Reviewed-by: Alessio Bazzica <alessiob@webrtc.org>
Commit-Queue: Alessio Bazzica <alessiob@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27106}
This reverts commit 6330818ec8.
Reason for revert: This breaks api/test/neteq_simulator_factory.cc, which unfortunately was not caught by our bots.
Original change's description:
> NetEQ RTP Play: Optionally write output audio file
>
> This CL makes the output audio file optional to more
> quickly run neteq_rtpplay when no audio output is needed.
> The CL also includes necessary adaptations because of pre-existing
> dependencies (e.g., the output audio file name is used to create
> the plotting script file names).
>
> The command line arguments are retro-compatible - i.e., same behavior
> when specifying the output audio file and the new flag
> --output_files_base_name is not used.
>
> This CL also includes a test script with which the retro-compatibility
> has been verified.
>
> Bug: webrtc:10337
> Change-Id: Ie3f301b3b2ed0682fb74426d9cf452396f2b112b
> Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/126224
> Commit-Queue: Alessio Bazzica <alessiob@webrtc.org>
> Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#27067}
TBR=henrik.lundin@webrtc.org,alessiob@webrtc.org,ivoc@webrtc.org
Change-Id: I0c63a8ba9566ef567ee398f571f2a511916fa742
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: webrtc:10337
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/127293
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Commit-Queue: Ivo Creusen <ivoc@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27078}
This CL makes the output audio file optional to more
quickly run neteq_rtpplay when no audio output is needed.
The CL also includes necessary adaptations because of pre-existing
dependencies (e.g., the output audio file name is used to create
the plotting script file names).
The command line arguments are retro-compatible - i.e., same behavior
when specifying the output audio file and the new flag
--output_files_base_name is not used.
This CL also includes a test script with which the retro-compatibility
has been verified.
Bug: webrtc:10337
Change-Id: Ie3f301b3b2ed0682fb74426d9cf452396f2b112b
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/126224
Commit-Queue: Alessio Bazzica <alessiob@webrtc.org>
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27067}
This cl deprecates the FrameType enum, and adds aliases AudioFrameType
and VideoFrameType.
After downstream usage is updated, the enums will be separated
and be moved out of common_types.h.
Bug: webrtc:6883
Change-Id: I2aaf660169da45f22574b4cbb16aea8522cc07a6
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/123184
Commit-Queue: Niels Moller <nisse@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#27011}
I will deprecate deps in proto_library for improved build throughput.
We can use link_deps here instead.
Bug: chromium:938011
Change-Id: Iafa83000c3f7f9ffdc0c376a2297b4a9380b7594
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/125820
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Commit-Queue: Takuto Ikuta <tikuta@google.com>
Cr-Commit-Position: refs/heads/master@{#26989}
This is a reland of d9f798a6b3
Original change's description:
> Remove field trial include from decision logic.
>
> Bug: webrtc:9289
> Change-Id: I2e465bf9eddda8bde50daeb14cfd51405e536ff4
> Reviewed-on: https://webrtc-review.googlesource.com/c/125097
> Reviewed-by: Minyue Li <minyue@webrtc.org>
> Commit-Queue: Jakob Ivarsson <jakobi@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#26925}
Bug: webrtc:9289
Change-Id: I40fbd999fc8495beaeb46799c333f91d72b5be37
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/125720
Reviewed-by: Minyue Li <minyue@webrtc.org>
Commit-Queue: Minyue Li <minyue@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26978}
Since there is no way to enable/disable these diagnostics at runtime,
this CL moves the suppression into the rtc_* templates in order to
remove the need to explicitly add the snippet of code needed to
suppress it (currently copy/pasted in 144 locations).
The diagnostic that causes the most problems is the one about "complex
class/struct explicit ctor/dtor" [1] because WebRTC doesn't find
it useful enough.
Other diagnostics are good (for example the one that warns about
using "virtual" instead of "override", but that will be covered by
this clang-tidy check [2]) while others are Chromium related so
they have never triggered.
[1] - https://cs.chromium.org/chromium/src/tools/clang/plugins/FindBadConstructsConsumer.cpp?l=147-167&rcl=b4bebe1aa15dba7ca5fcc6456a81a55665327c3a
[2] - https://clang.llvm.org/extra/clang-tidy/checks/modernize-use-override.html
Bug: webrtc:163
Change-Id: Icbf27efa5b369100a31e6a32df1a0913729b3b34
Reviewed-on: https://webrtc-review.googlesource.com/c/125088
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26918}
Previously, if more than one packet is extracted in a GetAudio call then
an incorrect number of samples will be reported.
Bug: webrtc:10363
Change-Id: Ia1bcc87a0e0082060e4f746d37a4008735eec6b3
Reviewed-on: https://webrtc-review.googlesource.com/c/124829
Reviewed-by: Minyue Li <minyue@webrtc.org>
Commit-Queue: Jakob Ivarsson <jakobi@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26903}
This replaces the use of command-line flags with the use of a config
struct. This makes it easier for non command-line applications to use
the NetEqTestFactory to run simulations.
Bug: webrtc:10337
Change-Id: I24533bf206e70e12db9af8d9675769c1ff7c7d48
Reviewed-on: https://webrtc-review.googlesource.com/c/123600
Reviewed-by: Pablo Barrera González <barrerap@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Ivo Creusen <ivoc@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26887}
- This mode estimates relative packet arrival delay for each incoming packet and adds that value to the histogram.
- The histogram buckets are 20 milliseconds each instead of whole packets.
- The functionality is enabled with a field trial for experimentation.
Bug: webrtc:10333
Change-Id: I8f7499c56802fc1aa1ced2f5310fdd2ef1403515
Reviewed-on: https://webrtc-review.googlesource.com/c/123923
Commit-Queue: Jakob Ivarsson <jakobi@webrtc.org>
Reviewed-by: Minyue Li <minyue@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26871}
Import proto_library.gni when rtc_enable_protobuf is true instead of when
build_with_mozilla is false.
Makes it maybe easier to reason about the intention (e.g. intention is to not
compile any protobuf in, hence flag rtc_enable_protobuf)
The build file could not work if build_with_mozilla = true but
rtc_enable_protobuf = true.
Bug: webrtc:10338
Change-Id: I26e5983bd1519aa46c308b11796d518de5ef7597
Reviewed-on: https://webrtc-review.googlesource.com/c/123763
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26868}
For e.g. when audio receiver is recreated during SetRtpExtensionsAndRecreateStream in webrtc_voice_engine.h,
the audio minimum delay can't go down.
Imagine we set base minimum playout delay when audio receiver stream is created, then its value will be cached, to be applied during recreation. Then SetRtpExtensionsAndRecreateStream is fired, and audio receiver stream is recreated with the cached value, but currently it in the constructor it is used to initialize both base minimum playout delay and minimum playout delay. Which leads to the bug that effective minimum playout delay can't go down anymore as if you set base minimum playout delay to the low value then effective delay use the biggest value which minimum playout delay.
This didn't come up during previous trials because of
https://webrtc-review.googlesource.com/c/src/+/122280
It was reseting minimum playout delay to 0 asynchronously, that is why you couldn't see this bug.
Bug: webrtc:10287
Change-Id: I924446bfcb33ac94f7e5bf987a1868acaf1b0346
Reviewed-on: https://webrtc-review.googlesource.com/c/124000
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Commit-Queue: Ruslan Burakov <kuddai@google.com>
Cr-Commit-Position: refs/heads/master@{#26832}
The difference to the original is new bitexactness strings. The
reason for reland is breaking downstream projects.
Original CL description:
Tests for multi-stream Opus.
This CL (mainly) adds bit-exactness tests for multi-stream Opus. The
tests are in audio_coding_unittest.cc. Some refactoring of
AcmSendTestOldApi, AcmSenderBitExactnessOldApi is done to make it
possible. A few checks for "channels \in {1, 2}" are replaced with
"channels \in {1, 2, 4, 6, 8}" in the WebRTC Opus codec wrapper. A few
other changes are made to be able to write and read multi-channel WAV
files.
The SDP changes are NOT included; as of this CL there is no way to set
up a multi-stream opus en/de-coder from SDP strings.
TBR=ossu@webrtc.org
Bug: webrtc:8649
Change-Id: I6261b18c69fd666d43ab34ed8f1bc9d5cc82b21f
Reviewed-on: https://webrtc-review.googlesource.com/c/123882
Reviewed-by: Alex Loiko <aleloi@webrtc.org>
Commit-Queue: Alex Loiko <aleloi@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26809}
This reverts commit 5341aaccdb.
Reason for revert: Order of initialization of global static strings.
Original change's description:
> Reland of https://webrtc-review.googlesource.com/c/src/+/114883
>
> The difference to the original is new bitexactness strings AND
> global static file string constants. The reason for reland is breaking
> downstream projects.
>
> Original CL description:
>
> Tests for multi-stream Opus.
>
> This CL (mainly) adds bit-exactness tests for multi-stream Opus. The
> tests are in audio_coding_unittest.cc. Some refactoring of
> AcmSendTestOldApi, AcmSenderBitExactnessOldApi is done to make it
> possible. A few checks for "channels \in {1, 2}" are replaced with
> "channels \in {1, 2, 4, 6, 8}" in the WebRTC Opus codec wrapper. A few
> other changes are made to be able to write and read multi-channel WAV
> files.
>
> The SDP changes are NOT included; as of this CL there is no way to set
> up a multi-stream opus en/de-coder from SDP strings.
>
> Bug: webrtc:8649
> Change-Id: I9fd47c790c241c1876c4a731b0840bec30b4f1b2
> Reviewed-on: https://webrtc-review.googlesource.com/c/123387
> Reviewed-by: Oskar Sundbom <ossu@webrtc.org>
> Commit-Queue: Alex Loiko <aleloi@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#26774}
TBR=aleloi@webrtc.org,ossu@webrtc.org
Change-Id: I88060f2050ccee83d6091b042a10f79b3c4edc47
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: webrtc:8649
Reviewed-on: https://webrtc-review.googlesource.com/c/123580
Reviewed-by: Alex Loiko <aleloi@webrtc.org>
Commit-Queue: Alex Loiko <aleloi@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26777}
The difference to the original is new bitexactness strings AND
global static file string constants. The reason for reland is breaking
downstream projects.
Original CL description:
Tests for multi-stream Opus.
This CL (mainly) adds bit-exactness tests for multi-stream Opus. The
tests are in audio_coding_unittest.cc. Some refactoring of
AcmSendTestOldApi, AcmSenderBitExactnessOldApi is done to make it
possible. A few checks for "channels \in {1, 2}" are replaced with
"channels \in {1, 2, 4, 6, 8}" in the WebRTC Opus codec wrapper. A few
other changes are made to be able to write and read multi-channel WAV
files.
The SDP changes are NOT included; as of this CL there is no way to set
up a multi-stream opus en/de-coder from SDP strings.
Bug: webrtc:8649
Change-Id: I9fd47c790c241c1876c4a731b0840bec30b4f1b2
Reviewed-on: https://webrtc-review.googlesource.com/c/123387
Reviewed-by: Oskar Sundbom <ossu@webrtc.org>
Commit-Queue: Alex Loiko <aleloi@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26774}
This reverts commit 9c31ac2323.
Reason for revert: Breaks downstream project.
Original change's description:
> Tests for multi-stream Opus.
>
> This CL (mainly) adds bit-exactness tests for multi-stream Opus. The
> tests are in audio_coding_unittest.cc. Some refactoring of
> AcmSendTestOldApi, AcmSenderBitExactnessOldApi is done to make it
> possible. A few checks for "channels \in {1, 2}" are replaced with
> "channels \in {1, 2, 4, 6, 8}" in the WebRTC Opus codec wrapper. A few
> other changes are made to be able to write and read multi-channel WAV
> files.
>
> The SDP changes are NOT included; as of this CL there is no way to set
> up a multi-stream opus en/de-coder from SDP strings.
>
> Bug: webrtc:8649
> Change-Id: I1d93a9b8eecc3f6e19896ff2e2ce9b63da77a23c
> Reviewed-on: https://webrtc-review.googlesource.com/c/114883
> Reviewed-by: Oskar Sundbom <ossu@webrtc.org>
> Commit-Queue: Alex Loiko <aleloi@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#26742}
TBR=aleloi@webrtc.org,ossu@webrtc.org
Change-Id: I0ac48b7320d31d3e7af33bf8714c3db6c807b82e
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: webrtc:8649
Reviewed-on: https://webrtc-review.googlesource.com/c/123385
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26747}
This CL (mainly) adds bit-exactness tests for multi-stream Opus. The
tests are in audio_coding_unittest.cc. Some refactoring of
AcmSendTestOldApi, AcmSenderBitExactnessOldApi is done to make it
possible. A few checks for "channels \in {1, 2}" are replaced with
"channels \in {1, 2, 4, 6, 8}" in the WebRTC Opus codec wrapper. A few
other changes are made to be able to write and read multi-channel WAV
files.
The SDP changes are NOT included; as of this CL there is no way to set
up a multi-stream opus en/de-coder from SDP strings.
Bug: webrtc:8649
Change-Id: I1d93a9b8eecc3f6e19896ff2e2ce9b63da77a23c
Reviewed-on: https://webrtc-review.googlesource.com/c/114883
Reviewed-by: Oskar Sundbom <ossu@webrtc.org>
Commit-Queue: Alex Loiko <aleloi@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26742}
On NetEq level latency corresponds to delay and two terms can be used interchangeably here.
In order to implement latency constraint we need to provide a range of possible values which should be constant. See getCapabilities() here:
https://www.w3.org/TR/mediacapture-streams/#dfn-applyconstraints-algorithm
Lowest possible value accepted value is constant and equals 0. But because |packet_len_ms_| and |maximum_delay_ms_| may be updated during live of DelayManager upper bound is not constant. Moreover, due to change in |packet_len_ms_| the |minimum_delay_ms_| which was valid when its was set may be considered invalid later on.
To circumvent that and provide constant range for capabilities we separate base minimum delay and minimum delay. ApplyConstraints algorithm will set base minimum delay. Base minimum delay will act as recommendation for lower bound of minimum delay and will be used to limit target delay. If user sets base minimum delay through ApplyConstraints which is bigger than currently
possible maximum (e.g. bigger than NetEq maximum buffer size in milliseconds) then base minimum delay will be clamped to currently possible maximum to match user's intentions as best as possible.
Note, that we keep original behavior when minimum_delay_ms_ (effective_minimum_delay_ms after this CL) in LimitTargetLevel method may be above upper bound due to changing packet audio length.
Bug: webrtc:10287
Change-Id: I06b8f5cd3fd1bc36800af0447f91f7c4dc21a766
Reviewed-on: https://webrtc-review.googlesource.com/c/121700
Commit-Queue: Ruslan Burakov <kuddai@google.com>
Reviewed-by: Minyue Li <minyue@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26666}
Currently, if the last packet was reordered (e.g. due to retransmission) then the next packet's inter-arrival time will be estimated incorrectly due to the jump in sequence numbers. This change prevents that by not resetting the stopwatch on reordered packets.
This will also better estimate inter-arrival times when we have multiple reordered packets in a burst. Currently we would only measure the iat of the first reordered packet correctly and not the ones coming after it.
There is a slight risk introducing this: If we would receive an out of order packet far into the future (in sequence numbers) and then continue getting packets in the normal order, then we would not update the current sequence number for these and incorrectly estimate their inter-arrival times since they would all be considered reordered.
Change-Id: Ic938a37cbddf1cb9c30b610218f56794568d3d01
Bug: webrtc:10178
Reviewed-on: https://webrtc-review.googlesource.com/c/119949
Reviewed-by: Minyue Li <minyue@webrtc.org>
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Commit-Queue: Jakob Ivarsson <jakobi@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26572}
This is first step to allow to set latency
from client code in Chromium.
Existing minimum latency hasn't been used because it can clash
with video syncronization code.
Bug: webrtc:10287
Change-Id: Ia38906506069a1abfa01698dc62df283fc15cfbc
Reviewed-on: https://webrtc-review.googlesource.com/c/121423
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Commit-Queue: Ruslan Burakov <kuddai@google.com>
Cr-Commit-Position: refs/heads/master@{#26536}
Googletest recently started replacing the term Test Case by Test Suite.
From now on, the preferred API is TestSuite*; the older TestCase* API
will be slowly deprecated.
This CL moves WebRTC to the new set of APIs.
More info in [1].
This CL has been generated with this script:
declare -A items
items[TYPED_TEST_CASE]=TYPED_TEST_SUITE
items[TYPED_TEST_CASE_P]=TYPED_TEST_SUITE_P
items[REGISTER_TYPED_TEST_CASE_P]=REGISTER_TYPED_TEST_SUITE_P
items[INSTANTIATE_TYPED_TEST_CASE_P]=INSTANTIATE_TYPED_TEST_SUITE_P
items[INSTANTIATE_TEST_CASE_P]=INSTANTIATE_TEST_SUITE_P
for i in "${!items[@]}"
do
git ls-files | xargs sed -i "s/\b$i\b/${items[$i]}/g"
done
git cl format
[1] - https://github.com/google/googletest/blob/master/googletest/docs/primer.md#beware-of-the-nomenclature
Bug: None
Change-Id: I5ae191e3046caf347aeee01554d5743548ab0e3f
Reviewed-on: https://webrtc-review.googlesource.com/c/118701
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26494}
This prepares for making the Clock interface fully mutable.
Calls to the time functions in Clock can have side effects in some
circumstances. It's also questionable if it's a good idea to allow
repeated calls to a const method return different values without
any changed to the class instance.
Bug: webrtc:9883
Change-Id: I96fb9230705f7c80a4c0702132fd9dc73899fc5e
Reviewed-on: https://webrtc-review.googlesource.com/c/120347
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26467}
This is a reland of
https://webrtc-review.googlesource.com/c/src/+/111750.
This time we don't use the multistream decoder unless we have to.
(Which is when #channels >2). Pros: don't make downstream projects
crash due to used up stack space, a few % more efficiency for the
typical case (because multistream adds some overhead). Cons: Messy
C-code with "union" types and #define MACROs, probably more
maintenance.
Bug: webrtc:8649
Change-Id: I4253a5e0c382f67ac7c6731dc6602a31e6779e63
Reviewed-on: https://webrtc-review.googlesource.com/c/120049
Commit-Queue: Alex Loiko <aleloi@webrtc.org>
Reviewed-by: Minyue Li <minyue@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26445}
This CL applies clang-tidy's performance-inefficient-vector-operation
[1] on the WebRTC codebase.
All changes in this CL are automatically generated by both clang-tidy
and 'git cl format'.
[1] - https://clang.llvm.org/extra/clang-tidy/checks/performance-inefficient-vector-operation.html
Bug: webrtc:10252
Change-Id: I824caab2a5746036852e00d714b89aa5ec030ee3
Reviewed-on: https://webrtc-review.googlesource.com/c/120052
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26442}
This CL applies clang-tidy's performance-for-range-copy [1] on the
WebRTC codebase.
All changes in this CL are automatically generated by both clang-tidy
and 'git cl format'.
[1] - https://clang.llvm.org/extra/clang-tidy/checks/performance-for-range-copy.html
Bug: webrtc:10215
Change-Id: I7c83290b8866d76129bbec4e24e6701f5014102e
Reviewed-on: https://webrtc-review.googlesource.com/c/120043
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26420}
The type rtc::scoped_refptr<T> is now part of api/. Please include it from
api/scoped_refptr.h.
More info: See: https://groups.google.com/forum/#!topic/discuss-webrtc/Mme2MSz4z4o.
Bug: webrtc:9887, webrtc:8205
No-Try: True
Change-Id: Ic6c7c81e226e59f12f7933e472f573ae097b55bf
Reviewed-on: https://webrtc-review.googlesource.com/c/119041
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26414}
This is a reland of 80b95de765
Original change's description:
> Trim down FileWrapper class to be merely a wrapper owning a FILE*
>
> Bug: webrtc:6463
> Change-Id: If71e2f3a75dc1863bc805ab71de1e2d33294f805
> Reviewed-on: https://webrtc-review.googlesource.com/c/117881
> Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
> Reviewed-by: Alex Loiko <aleloi@webrtc.org>
> Commit-Queue: Niels Moller <nisse@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#26311}
Bug: webrtc:6463
Change-Id: I12154ef65744c1b7811974a1d871e05ed3fbbc27
Reviewed-on: https://webrtc-review.googlesource.com/c/118660
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26337}
In particular, time_utils.h is currently pulled in via rtc_event.h
This CL is in preparation of moving parts of the RTC event log to api/.
Bug: webrtc:10206
Change-Id: Idd35aa9404afded4d29b1296344996c45b8c2e91
Reviewed-on: https://webrtc-review.googlesource.com/c/117921
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Stefan Holmer <stefan@webrtc.org>
Commit-Queue: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26326}
This reverts commit 83ed89a45f.
Reason for revert: breaks downstream project
Original change's description:
> Opus multistream.
>
> This is a backwards-compatible change. It makes WebRTC use the Opus
> multistream decoder for all Opus packets. Single-stream packets are a
> special case of multistream ones (with stream=1).
>
> The tricky parts are 'WebRtcOpus_GetMaxPlaybackRate' and
> 'WebRtcOpus_GetSurroundParameters'. GetMaxPlaybackRate is supposed to
> do what opus_encoder_ctl(encoder, OPUS_GET_MAX_BANDWIDTH(&bandwidth))
> did when we had single-stream encoders. Now there may be several
> independent encoders with possibly different BANDWIDTH. The new
> GetMaxPlaybackRate queries all of them, and returns a playback rate if
> all the encoder's rates are equal.
>
> WebRtcOpus_GetSurroundParameters is a configuration convention. It
> maps the number of channels to a multi-stream encoder/decoder
> configuration. As described in RFC 7845
> https://tools.ietf.org/html/rfc7845#section-5.1.1, a multi-stream
> encoder/decoder needs a number of streams, number of coupled streams
> and a 255-byte mapping array. The function GetSurroundParameters
> computes all of these from the number of channels. [1, 2, 4, 6, 8]
> channels are supported.
>
> Bug: webrtc:8649
> Change-Id: I271de8e387d738254d6aa53af7fcf8644a53edb5
> Reviewed-on: https://webrtc-review.googlesource.com/c/111750
> Commit-Queue: Alex Loiko <aleloi@webrtc.org>
> Reviewed-by: Minyue Li <minyue@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#26293}
TBR=aleloi@webrtc.org,minyue@webrtc.org
Change-Id: I1002e3273b44d3cccacdba84b8c363eefd537c4b
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: webrtc:8649
Reviewed-on: https://webrtc-review.googlesource.com/c/118201
Reviewed-by: Amit Hilbuch <amithi@webrtc.org>
Commit-Queue: Amit Hilbuch <amithi@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26306}
This is a backwards-compatible change. It makes WebRTC use the Opus
multistream decoder for all Opus packets. Single-stream packets are a
special case of multistream ones (with stream=1).
The tricky parts are 'WebRtcOpus_GetMaxPlaybackRate' and
'WebRtcOpus_GetSurroundParameters'. GetMaxPlaybackRate is supposed to
do what opus_encoder_ctl(encoder, OPUS_GET_MAX_BANDWIDTH(&bandwidth))
did when we had single-stream encoders. Now there may be several
independent encoders with possibly different BANDWIDTH. The new
GetMaxPlaybackRate queries all of them, and returns a playback rate if
all the encoder's rates are equal.
WebRtcOpus_GetSurroundParameters is a configuration convention. It
maps the number of channels to a multi-stream encoder/decoder
configuration. As described in RFC 7845
https://tools.ietf.org/html/rfc7845#section-5.1.1, a multi-stream
encoder/decoder needs a number of streams, number of coupled streams
and a 255-byte mapping array. The function GetSurroundParameters
computes all of these from the number of channels. [1, 2, 4, 6, 8]
channels are supported.
Bug: webrtc:8649
Change-Id: I271de8e387d738254d6aa53af7fcf8644a53edb5
Reviewed-on: https://webrtc-review.googlesource.com/c/111750
Commit-Queue: Alex Loiko <aleloi@webrtc.org>
Reviewed-by: Minyue Li <minyue@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26293}
NetEq currently only passes `jitterBufferDelay` to `getStats()`. We need its paired `jitterBufferEmittedCount` denominator stat for the calculations to be accurate.
Bug: webrtc:10192
Change-Id: I655aea629026ce9101409c2e0f18c2fa57a1c3ab
Reviewed-on: https://webrtc-review.googlesource.com/c/117320
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Commit-Queue: Chen Xing <chxg@google.com>
Cr-Commit-Position: refs/heads/master@{#26276}
A trimmed down version is moved to legacy_encoded_audio_frame_unittest.cc
where it's used for test parameterization.
Bug: webrtc:10185
Change-Id: I9abda22f9806b831b6ca4b27d6bcc888285f50f2
Reviewed-on: https://webrtc-review.googlesource.com/c/116961
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Commit-Queue: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26218}
When enabled, the delay manager is updated with reordered packets. It also makes the peak detector ignore the reordered packets.
Change-Id: I2bdc99764cc76b15e613ed3dc75f83aaf66eee4e
Bug: webrtc:10178
Reviewed-on: https://webrtc-review.googlesource.com/c/116481
Commit-Queue: Jakob Ivarsson <jakobi@webrtc.org>
Reviewed-by: Minyue Li <minyue@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26187}
This fixes a bug where we sometimes extract an Opus CNG packet and the packet after, even though there was big timestamp gap between the packets, which causes expansion during the next GetAudio calls.
Change-Id: I2409ac08df58afc496f74b91981657b7206e8bb1
Bug: webrtc:10167
Reviewed-on: https://webrtc-review.googlesource.com/c/115419
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Commit-Queue: Jakob Ivarsson <jakobi@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26179}
The ANA frame length controller requires the provided frame lengths supported by the encoder to be ordered. A data structural guarantee of such was in an earlier version but was accidentally removed since https://codereview.webrtc.org/2429503002. This CL uses std::set to ensure that again.
Change-Id: Ia197dbf6a34f02506e81c9f49d6cd60e4cdacef4
BUG: webrtc:6303
Reviewed-on: https://webrtc-review.googlesource.com/c/115946
Reviewed-by: Stefan Holmer <stefan@webrtc.org>
Commit-Queue: Minyue Li <minyue@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26119}
The following APIs on AudioCodingModule are deprecated with this CL:
static int NumberOfCodecs();
static int Codec(int, CodecInst*);
static int Codec(const char*, CodecInst*, int, size_t);
static int Codec(const char*, int, size_t);
absl::optional<CodecInst> SendCodec() const;
bool RegisterReceiveCodec(int, const SdpAudioFormat&);
int RegisterExternalReceiveCodec(int, AudioDecoder*, int, int, const std::string&);
int UnregisterReceiveCodec(uint8_t);
int32_t ReceiveCodec(CodecInst*);
absl::optional<SdpAudioFormat> ReceiveFormat();
As well as this method on RtpRtcp module:
int32_t RegisterSendPayload(const CodecInst&);
Bug: webrtc:7626
Change-Id: I1230732136f1fe9048cf74afdeab767ca57ac9ce
Reviewed-on: https://webrtc-review.googlesource.com/c/113816
Commit-Queue: Fredrik Solenberg <solenberg@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26025}
This will print out the major events during a NetEq simulation.
Bug: b/116685514
Change-Id: Iab172e9a9115695b42c67628d5523c727359bb89
Reviewed-on: https://webrtc-review.googlesource.com/c/114320
Commit-Queue: Ivo Creusen <ivoc@webrtc.org>
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26019}
Using GetAudio events from SSRCs without incoming packets doesn't make sense, and should be prevented.
Bug: b/116685514
Change-Id: I48e38bb780549c71cb5f68d370a6819634ad487d
Reviewed-on: https://webrtc-review.googlesource.com/c/114321
Commit-Queue: Ivo Creusen <ivoc@webrtc.org>
Reviewed-by: Jakob Ivarsson <jakobi@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26017}
This CL removes all the instances of 'using namespace' from C++ code
(more info https://abseil.io/tips/153).
Bug: webrtc:9855
Change-Id: Ic940fe87c5047742cfa6d60857d2f97be380ed18
Reviewed-on: https://webrtc-review.googlesource.com/c/113948
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25985}
This change converts all tests but CodecInternalCng and
DecodingErrorDuringInternalCng, which depend on the obsolete Decode
method.
Bug: webrtc:10080
Change-Id: I34b068b3aa7139ed24bd63b417a5adcfc1de7922
Reviewed-on: https://webrtc-review.googlesource.com/c/113506
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25946}
Update audio_coding tests to not use CodecInst.
Bug: webrtc:7626
Change-Id: I880fb8d72d7d0a915d274e67feb6106f023697c2
Reviewed-on: https://webrtc-review.googlesource.com/c/112594
Commit-Queue: Fredrik Solenberg <solenberg@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25879}
This is a follow-up to
https://webrtc-review.googlesource.com/c/src/+/106280.
This time the whole code base is covered.
Some files may have not been fixed though, whenever the IWYU tool
was breaking the build.
Bug: webrtc:8311
Change-Id: I2c31f552a87e887d33931d46e87b6208b1e483ef
Reviewed-on: https://webrtc-review.googlesource.com/c/111965
Commit-Queue: Yves Gerey <yvesg@google.com>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25830}
The ssrc for a given NetEq instance shouldn't change.
Bug: webrtc:7135
Change-Id: Iee0d4cd8bd5d917e819fa2ecf45a40e203c6d9c0
Reviewed-on: https://webrtc-review.googlesource.com/c/111661
Reviewed-by: Fredrik Solenberg <solenberg@webrtc.org>
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Commit-Queue: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25825}
Note that this value will override the minimum delay that is used for audio/video sync.
Bug: webrtc:10053
Change-Id: Ia129f6c9ee9da5d00a3d955afaaa6e8f0c2bee33
Reviewed-on: https://webrtc-review.googlesource.com/c/112121
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Commit-Queue: Jakob Ivarsson <jakobi@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25805}
The stat will be exposed through origin trial described in:
https://docs.google.com/document/d/1stYIZhEmDZ7NJF9gjjsM66eLFJUdc-14a3QutrFbIwI
Change-Id: Ib191a11c6bd9e617abbe9dd82239b0c5b4e6b4e0
Bug: webrtc:10043
Reviewed-on: https://webrtc-review.googlesource.com/c/111922
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Reviewed-by: Minyue Li <minyue@webrtc.org>
Commit-Queue: Jakob Ivarsson <jakobi@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25802}
The fuzzers detected a possible overflow in the multiplication of sum and gainQ10.
Since gainQ10 cannot be larger than 2048000 (see WebRtcIsac_kQGain2Levels) and sum cannot be larger than 2^16, a int64 is large enough to hold the result.
Bug: chromium:904909
Change-Id: Icb12821d4006aaaaf70a5735d2abd2b96f7a2f0e
Reviewed-on: https://webrtc-review.googlesource.com/c/111921
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Commit-Queue: Jonas Olsson <jonasolsson@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25787}
This CL decouples //rtc_base:rtc_base_tests_utils from gunit by
moving gunit helpers (rtc_base/gunit.h) and rtc_base/testclient.h
(which depends on gunit helpers) to their own build target.
It also removes some unused dependencies in the WebRTC build graph.
Bug: None
Change-Id: Ia9820e84ff697da39b351eef73c45f6e4bdf2623
Reviewed-on: https://webrtc-review.googlesource.com/c/111861
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25769}
This is to let ANA config proto to fully control it.
Bug: b/119788974
Change-Id: Ib7842f784bdf879cb7d753c7077ce845f435a379
Reviewed-on: https://webrtc-review.googlesource.com/c/111741
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Commit-Queue: Minyue Li <minyue@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25764}
Since the link capacity is designed to be a more stable value, we don't
need the smoothing. This allows us to react faster to changes in link
capacity while still avoiding to react to changes in target bitrate due
to normal control behavior.
Bug: webrtc:9718
Change-Id: I2fbf6bb882f312a7b28ea43d27057886d035ac45
Reviewed-on: https://webrtc-review.googlesource.com/c/111511
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Minyue Li <minyue@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25745}
Expected checksums depend on whether libopus is built with SSE or not.
Since we have no robust way to know that and we cannot enforce all
clients to use SSE, we accept both results.
Bug: webrtc:9530
Bug: webrtc:9995
Change-Id: I9f0464ffec15df91eafe15d89c61e2140f341cb1
Reviewed-on: https://webrtc-review.googlesource.com/c/110789
Commit-Queue: Yves Gerey <yvesg@webrtc.org>
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25633}
Downstream projects need to be able to configure ANA without hacking or redefining protos.
Bug: webrtc:9719
Change-Id: Idd80471066ff41a9265adbdb738cc98cc97b2e6e
Reviewed-on: https://webrtc-review.googlesource.com/c/110765
Reviewed-by: Bjorn Mellem <mellem@webrtc.org>
Commit-Queue: Peter Slatala <psla@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25629}
We want to get rid of the whole thing, really, but these two were
easy.
Bug: webrtc:8396
Change-Id: I9292bf077caca171c9f5fe63695b6333cf22547d
Reviewed-on: https://webrtc-review.googlesource.com/c/104763
Commit-Queue: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25618}
After this CL, all audio encoders have to be injected by the caller.
This means that there is no special "built-in" set of codecs, and
users won't have to pay the binary size and security costs of codecs
they aren't using.
Bug: webrtc:8396
Change-Id: Idb0959ce395940c8bb3bbb49256cdcd84fc87bb6
Reviewed-on: https://webrtc-review.googlesource.com/c/103821
Commit-Queue: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25600}
It is currently not possible to run e.g. neteq_rtpplay in the fast
accelerate mode.
Bug: None
Change-Id: I5e0ce3fae2ad5585fe9fb545109bb0c9a87fd201
Reviewed-on: https://webrtc-review.googlesource.com/c/110162
Commit-Queue: Sam Zackrisson <saza@webrtc.org>
Reviewed-by: Minyue Li <minyue@webrtc.org>
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25561}
The .cc source files listed below #ifdef for WEBRTC_CODEC_OPUS and
WEBRTC_CODEC_ILBC but the build files don't include the defines.
modules/audio_coding/neteq/tools/neteq_test.cc
modules/audio_coding/neteq/tools/neteq_test_factory.cc
Bug: None
Change-Id: I6065021f68e58d0e5663acd006a9865bf265adc0
Reviewed-on: https://webrtc-review.googlesource.com/c/109925
Reviewed-by: Minyue Li <minyue@webrtc.org>
Commit-Queue: Sam Zackrisson <saza@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25555}
absl::make_unique is used in this file without absl/memory/memory.h
#include, that causes a build error on C++17 build of Chromium.
Bug: chromium:752720
Change-Id: I78fe9f76a6ea670a4250b4cf25c3c02cf4c4beb6
Reviewed-on: https://webrtc-review.googlesource.com/c/109540
Commit-Queue: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25514}
None of these scripts or files have been used in a very long time. They
are removed for the same reason, and since the data files add to the
weight of the resources folder.
Bug: webrtc:5289
Change-Id: Ia14a46aed180f286fa881fe5f60da6973a5fe027
Reviewed-on: https://webrtc-review.googlesource.com/c/109022
Commit-Queue: Oleh Prypin <oprypin@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25502}
And put codecs/cng/webrtc_cng.h in a non-public build target while
we're at it.
Bug: webrtc:8396
Change-Id: I9f51dffadfb645cd1454617fad30e09d639ff53c
Reviewed-on: https://webrtc-review.googlesource.com/c/108782
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Commit-Queue: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25486}
This CL consistently use:
* relative paths for WebRTC dependent targets (test_support)
* absolute paths for shared dependent targets (abseil)
This is a necessary (but insufficient) step to build WebRTC tests
from Chromium tree (rtc_include_tests=true), since test/ doesn't
sit anymore in the top level directory.
We also make sure that target declarations and uses are
consistent in regard to build_with_chromium flag.
Bug: webrtc:9943
Bug: webrtc:9855
Change-Id: I21dea98894df2fd4bfe2fd7ee7b71ba971e0ab5b
Reviewed-on: https://webrtc-review.googlesource.com/c/108720
Reviewed-by: Patrik Höglund <phoglund@webrtc.org>
Commit-Queue: Yves Gerey <yvesg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25445}
This CL is the result of running include-what-you-use tool on part
of the code base (audio target and dependencies) plus manual fixes.
bug: webrtc:8311
Change-Id: I277d281ce943c3ecc1bd45fd8d83055931743604
Reviewed-on: https://webrtc-review.googlesource.com/c/106280
Commit-Queue: Yves Gerey <yvesg@google.com>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Patrik Höglund <phoglund@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25311}
This is a reland of 5ccdc1331f
Original change's description:
> Prefix flag macros with WEBRTC_.
>
> Macros defined in rtc_base/flags.h are intended to be used to define
> flags in WebRTC's binaries (e.g. tests).
>
> They are currently not prefixed and this could cause problems with
> downstream clients since these names are quite common.
>
> This CL adds the 'WEBRTC_' prefix to them.
>
> Generated with:
>
> for x in DECLARE DEFINE; do
> for y in bool int float string FLAG; do
> git grep -l "\b$x\_$y\b" | \
> xargs sed -i "s/\b$x\_$y\b/WEBRTC_$x\_$y/g"
> done
> done
> git cl format
>
> Bug: webrtc:9884
> Change-Id: I7b524762b6a3e5aa5b2fc2395edd3e1a0fe72591
> Reviewed-on: https://webrtc-review.googlesource.com/c/106682
> Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
> Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#25270}
TBR=kwiberg@webrtc.org
Bug: webrtc:9884
Change-Id: I5ba5368a231a334d135ed5e6fd7a279629ced8a3
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://webrtc-review.googlesource.com/c/107161
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25277}
This reverts commit 5ccdc1331f.
Reason for revert: Breaks downstream project.
Original change's description:
> Prefix flag macros with WEBRTC_.
>
> Macros defined in rtc_base/flags.h are intended to be used to define
> flags in WebRTC's binaries (e.g. tests).
>
> They are currently not prefixed and this could cause problems with
> downstream clients since these names are quite common.
>
> This CL adds the 'WEBRTC_' prefix to them.
>
> Generated with:
>
> for x in DECLARE DEFINE; do
> for y in bool int float string FLAG; do
> git grep -l "\b$x\_$y\b" | \
> xargs sed -i "s/\b$x\_$y\b/WEBRTC_$x\_$y/g"
> done
> done
> git cl format
>
> Bug: webrtc:9884
> Change-Id: I7b524762b6a3e5aa5b2fc2395edd3e1a0fe72591
> Reviewed-on: https://webrtc-review.googlesource.com/c/106682
> Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
> Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#25270}
TBR=mbonadei@webrtc.org,kwiberg@webrtc.org
Change-Id: Ia79cd6066ecfd1511c34f1b30fd423e560ed6854
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: webrtc:9884
Reviewed-on: https://webrtc-review.googlesource.com/c/107160
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25276}
Macros defined in rtc_base/flags.h are intended to be used to define
flags in WebRTC's binaries (e.g. tests).
They are currently not prefixed and this could cause problems with
downstream clients since these names are quite common.
This CL adds the 'WEBRTC_' prefix to them.
Generated with:
for x in DECLARE DEFINE; do
for y in bool int float string FLAG; do
git grep -l "\b$x\_$y\b" | \
xargs sed -i "s/\b$x\_$y\b/WEBRTC_$x\_$y/g"
done
done
git cl format
Bug: webrtc:9884
Change-Id: I7b524762b6a3e5aa5b2fc2395edd3e1a0fe72591
Reviewed-on: https://webrtc-review.googlesource.com/c/106682
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25270}
When a LOG_END event is reached, it makes no sense to continue simulating NetEq.
Bug: webrtc:9667
Change-Id: Ie4f6811cdec0d0632f6e7906059e0e74e9f10438
Reviewed-on: https://webrtc-review.googlesource.com/c/105643
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Reviewed-by: Minyue Li <minyue@webrtc.org>
Commit-Queue: Ivo Creusen <ivoc@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25176}
Extract functionality of test_main into separate library to be able to
reuse it if another main will be required.
Bug: webrtc:5996
Change-Id: I2925b4240bd0e4fb884b43bb16667ca2d6216bbd
Reviewed-on: https://webrtc-review.googlesource.com/c/105921
Reviewed-by: Patrik Höglund <phoglund@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Commit-Queue: Artem Titov <titovartem@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25172}
There is currently no way to set this for simulations in neteq_rtpplay.
Bug: webrtc:9667
Change-Id: I34f34565538bd3c378cdb9d355f5173c3517d59a
Reviewed-on: https://webrtc-review.googlesource.com/c/105982
Reviewed-by: Minyue Li <minyue@webrtc.org>
Commit-Queue: Ivo Creusen <ivoc@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25171}
Add options to:
1. Bypass optimization (use reported packet loss).
2. Set a maximum value.
3. Set a coefficient.
Bug: webrtc:9866
Change-Id: I3fef43e5186a4f0f50fda3506e445860518cfbd7
Reviewed-on: https://webrtc-review.googlesource.com/c/105304
Commit-Queue: Jakob Ivarsson <jakobi@webrtc.org>
Reviewed-by: Minyue Li <minyue@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25161}
Also remove header extension map from NetEqEventLogInput and RtcEventLogSource.
Bug: webrtc:8111
Change-Id: Ic9be7b03e32ab8aa12284596e21e53b6763f483a
Reviewed-on: https://webrtc-review.googlesource.com/c/102622
Commit-Queue: Björn Terelius <terelius@webrtc.org>
Reviewed-by: Minyue Li <minyue@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25122}
SetExecutablePath isn't used anymore.
Nobody was using the fancy select-per-platform functionality, and the
documentation was wrong anyway. In the cases somebody needed an
override per platform, they were using defines in their own test
instead. I think that is more verbose but more predictable and easy
to understand (see how it's done in audio_processing_unittest.cc
when loading output_data_mac, for instance).
Bug: webrtc:9792
Change-Id: I7289bf5883fe43852638922d7c7583eae0c08601
Reviewed-on: https://webrtc-review.googlesource.com/c/104482
Commit-Queue: Patrik Höglund <phoglund@webrtc.org>
Reviewed-by: Artem Titov <titovartem@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25062}
Some important NetEq information was not available in NetEqState, which
meant it was not available on the API. This CL adds additional
information.
Bug: webrtc:9667
Change-Id: I702707c7d60472f488047d48fb286f839c5608dc
Reviewed-on: https://webrtc-review.googlesource.com/c/102300
Reviewed-by: Minyue Li <minyue@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Ivo Creusen <ivoc@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24985}
It will soon lose the ability to do so.
Bug: webrtc:8396
Change-Id: If120afa37325c00ae2c3e9a9bd75bf89c8897f8c
Reviewed-on: https://webrtc-review.googlesource.com/c/103441
Commit-Queue: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24979}
UBSan will trigger when time_stretched_samples overflows using a
big number. This change avoids this problem by storing the
intermediate result into a int64_t.
Bug: chromium:886904
Change-Id: Id09dc4b468f841f03b523d5f21763f610b163a42
Reviewed-on: https://webrtc-review.googlesource.com/c/103123
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Commit-Queue: Pablo Barrera González <barrerap@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24977}
After the removal of field_trial_default, metrics_default and
runtime_enabled_features_default, this build target doesn't build
anything and can be safely removed.
Bug: webrtc:9631
Change-Id: Iee1111e065ffefe0b4b9a695ee67a594e6d82caa
Reviewed-on: https://webrtc-review.googlesource.com/c/103702
Reviewed-by: Oleh Prypin <oprypin@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24976}
It will soon lose the ability to do so.
Bug: webrtc:8396
Change-Id: I1d7c62fbc2585233cf1656fdcc4bb5380c2f41a5
Reviewed-on: https://webrtc-review.googlesource.com/c/100980
Commit-Queue: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24947}
It will soon lose the ability to do so.
Bug: webrtc:8396
Change-Id: I06dce417bba855b57130bd1a052988b2f235dcbd
Reviewed-on: https://webrtc-review.googlesource.com/102882
Commit-Queue: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24921}
This CL removes some deprecated build targets (and their headers)
from system_wrappers:
- field_trial_api
- field_trial_default
- metrics_api
- metrics_default
It also refreshes all the dependencies on field_trial.h and metrics.h.
A nice side effect is that it is finally possible to remove 'nogncheck'
from the following files (when it was used with field_trial_default
and metrics_default):
- sdk/objc/api/peerconnection/RTCMetricsSampleInfo+Private.h
- sdk/android/src/jni/pc/peerconnectionfactory.cc
- sdk/objc/api/peerconnection/RTCFieldTrials.mm
Bug: webrtc:9631
Change-Id: Ib621f41ef8ad0aba4fe1c1d7e749c044afc956c3
No-Try: True
Reviewed-on: https://webrtc-review.googlesource.com/100524
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24878}
It will soon lose the ability to do so.
Bug: webrtc:8396
Change-Id: I7d8e1549c44628fc9bdf2480468a0f1d3ae812f2
Reviewed-on: https://webrtc-review.googlesource.com/102062
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Commit-Queue: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24853}
The tests only use the automatic mode, and I'd rather not maintain
(and test!) the rest.
Bug: webrtc:8396
Change-Id: I4cd1096e088d2ea8807a605b8448bd44ff9e88ed
Reviewed-on: https://webrtc-review.googlesource.com/102060
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Commit-Queue: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24852}
It will soon lose the ability to do so.
Bug: webrtc:8396
Change-Id: Ifca101fce0c349dba8c402ab2b6ad614061a88f6
Reviewed-on: https://webrtc-review.googlesource.com/101281
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Commit-Queue: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24836}
It will soon lose the ability to do so.
Bug: webrtc:8396
Change-Id: Id413204e53afec28495dff0873f027a56caed80f
Reviewed-on: https://webrtc-review.googlesource.com/101861
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Commit-Queue: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24834}
It hasn't been changed in any meaningful way since 2013, the same year
it was created.
Bug: webrtc:8396
Change-Id: I5633188134f71f24311fbd3098d046632fc4ee3a
Reviewed-on: https://webrtc-review.googlesource.com/101563
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Commit-Queue: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24816}
It will soon lose the ability to do so.
Also, the ACM no longer creates comfort noise encoders for us, so
don't bother testing that.
Bug: webrtc:8396
Change-Id: I24a12e26bef142f9f8e7532b764f28572e0c6ace
Reviewed-on: https://webrtc-review.googlesource.com/101640
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Commit-Queue: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24803}
Replace calls to .str() which copies with .Release which moves in cases where that's safe.
This CL was generated by this command:
git grep -l 'StringBuilder' |
xargs perl -i -0 -pe "s/(rtc::StringBuilder (\S+);.*?return )\\g2.str\(\)/\$1\$2.Release\(\)/sg"
Bug: webrtc:8982
Change-Id: If4dadbeb039df010aaaa9e58da81c1971a84fe8f
Reviewed-on: https://webrtc-review.googlesource.com/100307
Commit-Queue: Jonas Olsson <jonasolsson@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24790}
Uninline RTPFragmentaion functions
fix RTPFragmentation move constructor and assign operators (was recursive for win)
replace assert with rtc::dchecked_cast
Remove unused includes and dependencies.
Fix other targets that used those includes transitively instead of directly
Bug: None
Change-Id: I647cb1eda107dc7d87d25234095545bc2842fa40
Reviewed-on: https://webrtc-review.googlesource.com/100500
Commit-Queue: Danil Chapovalov <danilchap@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24759}
This change enables NetEq to use the packet concealment audio (aka
PLC) produced by a decoder. The change also includes a new API to the
AudioDecoder interface, which lets the decoder implementation generate
and deliver concealment audio.
Bug: webrtc:9180
Change-Id: Icaacebccf645d4694b0d2d6310f6f2c7132881c4
Reviewed-on: https://webrtc-review.googlesource.com/96340
Commit-Queue: Henrik Lundin <henrik.lundin@webrtc.org>
Reviewed-by: Minyue Li <minyue@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24738}
Currently we use the NetworkStatistics to monitor these metrics, but because these get reset on every call, this makes it impossible to use them for other purposes.
Bug: webrtc:9667
Change-Id: If648085f04d2d58aae263cff5b9491bcad373a96
Reviewed-on: https://webrtc-review.googlesource.com/99740
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Commit-Queue: Ivo Creusen <ivoc@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24727}
It is problematic to set field trials more than once, so to avoid running into problems, this functionality has been placed in the main function of neteq_rtpplay.
Bug: webrtc:9667
Change-Id: Ib9b9990f30a1715b50889dbfc4d74787bcbe5dae
Reviewed-on: https://webrtc-review.googlesource.com/98541
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Minyue Li <minyue@webrtc.org>
Commit-Queue: Ivo Creusen <ivoc@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24673}
The NetEqTest class was recently refactored. In the process, the
functionality for measuring the simulation time suffered a bug. This
CL fixes it.
Bug: webrtc:9667
Change-Id: I139e697ede21584ef77ae23cfa8e77f6dac65b51
Reviewed-on: https://webrtc-review.googlesource.com/98982
Commit-Queue: Henrik Lundin <henrik.lundin@webrtc.org>
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24658}
This CL adds more useful information to NetEqState, and implements setting action_times_ms, which can be used to get a better idea of what actually happened during a timestep.
Bug: webrtc:9667
Change-Id: I789a3e1ad852066fdf4e9b4c96b8fb6033dacb27
Reviewed-on: https://webrtc-review.googlesource.com/98163
Reviewed-by: Minyue Li <minyue@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Ivo Creusen <ivoc@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24643}
This CL replaces std::o?stringstream with rtc::StringBuilder where that's possible to do without changing any of the surrounding code. It also updates includes and build files as appropriate.
The CL was generated by running 'git grep -l -P std::o?stringstream | xargs perl -pi -e "s/std::o?stringstream/rtc::StringBuilder/g"'. Then I've manually updated the #includes and BUILD files, run 'git cl format' and unstaged any file that would need more complex fixes.
Bug: webrtc:8982
Change-Id: Ibc32153f4a3fd177e260b6ad05ce393972549357
Reviewed-on: https://webrtc-review.googlesource.com/98460
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Jonas Olsson <jonasolsson@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24605}
This CL enables -Wexit-time-destructors and -Wglobal-constructors on
rtc_static_library and rtc_source_set build targets.
It also adds the possibility to suppress these warnings because
they trigger in a few places.
The long term goal is to avoid regressions on this and remove all the
suppressions.
Bug: webrtc:9693
Change-Id: I4c1ecc137ef9e87ec5e66981ce95d96fb082727c
Reviewed-on: https://webrtc-review.googlesource.com/98380
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24604}
Only user, iSACTest, refactored to use a sleep instead.
Bug: webrtc:3380
Change-Id: I683a5a05349f75a17e5d2a02d4a20a9cf059a28f
Reviewed-on: https://webrtc-review.googlesource.com/96802
Reviewed-by: Henrik Andreassson <henrika@webrtc.org>
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Commit-Queue: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24541}
Most of the code in neteq_rtpplay is moved into a factory class for
NetEqTest. The factory method takes the same argc and argv arguments as
neteq_rtpplay.
This CL also adds a small public API for neteq_test to allow easy
integration into external software.
Bug: webrtc:9667
Change-Id: I5241c1f51736cb6fbe47b0ad25f4bc83dabd727d
Reviewed-on: https://webrtc-review.googlesource.com/96100
Commit-Queue: Ivo Creusen <ivoc@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Reviewed-by: Minyue Li <minyue@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24531}
LappedTransform is only used in BandwidthAdaptationTest and therefore it
should not be anymore a visible target under common_audio.
This CL moves LappedTransform and other two classes it depends on (and which
are not used elsewhere) to modules/audio_coding/codecs/opus/test.
Bug: webrtc:9577, webrtc:5298
Change-Id: I1aa8052c2df2b2b150c279c0c9b1001474aed47a
Reviewed-on: https://webrtc-review.googlesource.com/96440
Commit-Queue: Alessio Bazzica <alessiob@webrtc.org>
Reviewed-by: Alex Loiko <aleloi@webrtc.org>
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24509}
Specifically, don't expect the ACM to be able to create encoders; we
have to give it an encoder that we make ourselves.
The new way of creating encoders used a 32 kbit/s bitrate
unconditionally for iSAC; I had to change it to 32 kbit/s for 16 kHz
and 56 kbit/s for 32 kHz, which is what the old way of creating
encoders has used since forever.
I also had to change some test expectations on Opus, because the new
way defaults to 32 kbit/s for mono and 64 kbit/s for stereo (which I
believe to be correct), while the old way defaults to 64 kbit/s in
both cases.
Bug: webrtc:8396
Change-Id: I3aab944175a8e27f4c63380e822b27e839bba7f2
Reviewed-on: https://webrtc-review.googlesource.com/94540
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Commit-Queue: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24375}
Specifically, don't expect the ACM to be able to create encoders; we
have to give it an encoder that we make ourselves.
Bug: webrtc:8396
Change-Id: I032b12f3813af6ac3ea0dfb688006899dffe4855
Reviewed-on: https://webrtc-review.googlesource.com/94150
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Commit-Queue: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24323}
This CL also excludes several codec mappings depending on compile-time flags.
Bug: webrtc:9289
Change-Id: I1a9183f88378307925b747576a5513e54be3782e
Reviewed-on: https://webrtc-review.googlesource.com/93462
Reviewed-by: Minyue Li <minyue@webrtc.org>
Commit-Queue: Ivo Creusen <ivoc@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24259}
Specifically, don't expect the ACM to be able to create encoders; we
have to give it an encoder that we make ourselves.
To make it work, I had to add support for the "ptime" parameter to the
L16 codec.
Bug: webrtc:8396
Change-Id: I3869422882611d2eed65d6c849ea7cd3ad6bd126
Reviewed-on: https://webrtc-review.googlesource.com/87423
Reviewed-by: Oskar Sundbom <ossu@webrtc.org>
Commit-Queue: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24217}
This CL removes //build/config/clang:find_bad_constructs from the
suppressed_configs list, which means that clang:find_bad_constructs
is now enabled on these translation units.
Bug: webrtc:9251, webrtc:163
Change-Id: I6a7d4964723a5e195189aac30a83d9e924e61dd7
Reviewed-on: https://webrtc-review.googlesource.com/89743
Reviewed-by: Oskar Sundbom <ossu@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24053}
WebRTC internal headers are always included starting from the root
(e.g. #include "modules/audio_coding/..."), so there is no need to
specify the include_dirs removed by this CL.
Bug: webrtc:9538
Change-Id: I91e70508c67020bbf70304df5e48ca757ad43221
Reviewed-on: https://webrtc-review.googlesource.com/89385
Reviewed-by: Oleh Prypin <oprypin@webrtc.org>
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24026}
This is an reland of 6f5b0f920a
Relanded after speculative revert without any changes.
TBR=ilnik@webrtc.org
Original change's description:
> Remove rtc::Optional alias and api:optional target
>
> Update left-overs where old target still was used.
>
> Bug: webrtc:9078
> Change-Id: I2162c928091fc4ff1dea33a3f03adbe47207d206
> Reviewed-on: https://webrtc-review.googlesource.com/84740
> Commit-Queue: Danil Chapovalov <danilchap@webrtc.org>
> Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#23913}
Bug: webrtc:9078
Change-Id: Ia33c6438253c6ec49f45d938e8a3607b51c418be
Reviewed-on: https://webrtc-review.googlesource.com/88160
Commit-Queue: Danil Chapovalov <danilchap@webrtc.org>
Reviewed-by: Ilya Nikolaevskiy <ilnik@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23941}
Update left-overs where old target still was used.
Bug: webrtc:9078
Change-Id: I2162c928091fc4ff1dea33a3f03adbe47207d206
Reviewed-on: https://webrtc-review.googlesource.com/84740
Commit-Queue: Danil Chapovalov <danilchap@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23913}
This CL makes NetEq handle nested RED packets without crashing. Nested
RED packets mean that the block PT (see
https://tools.ietf.org/html/rfc2198.html#section-3) in the RED packet
is also set to the RED PT. This implies a nested RED packet, which is
not supported. Instead, all payloads in a RED packet that have the RED
PT will be discarded.
Bug: chromium:851662
Change-Id: I86ec257e60fb8076e3574ac5a4a1ca50196f6b34
Reviewed-on: https://webrtc-review.googlesource.com/86824
Commit-Queue: Henrik Lundin <henrik.lundin@webrtc.org>
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23825}
Now that there is only one implementation of the decision logic, there
is no longer any need to have GetDecisionSpecialized being separate.
Bug: webrtc:9421
Change-Id: Id364ce09ac05d106652d749502058056f11bba27
Reviewed-on: https://webrtc-review.googlesource.com/86604
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Commit-Queue: Henrik Lundin <henrik.lundin@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23804}
Building NetEqEventLogInput requires protobuf support, while building
NetEqRtpDumpInput located in the same file does not. This makes both
classes unusable when protobuf support is lacking. With this CL, the
NetEqEventLogInput is broken out into separate files, to allow usage
of NetEqRtpDumpInput even when protobufs are not supported.
Bug: webrtc:9421
Change-Id: I55efec4ec259713654566cdaa00d2e34c5e9a60f
Reviewed-on: https://webrtc-review.googlesource.com/84587
Commit-Queue: Henrik Lundin <henrik.lundin@webrtc.org>
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23803}
This is a reland of 80c4cca491
Original change's description:
> NetEq: Deprecate playout modes Fax, Off and Streaming
>
> The playout modes other than Normal have not been reachable for a long
> time, other than through tests. It is time to deprecate them.
>
> The only meaningful use was that Fax mode was sometimes set from
> tests, in order to avoid time-stretching operations (accelerate and
> pre-emptive expand) from messing with the test results. With this CL,
> a new config is added instead, which lets the user specify exactly
> this: don't do time-stretching.
>
> As a result of Fax and Off modes being removed, the following code
> clean-up was done:
> - Fold DecisionLogicNormal into DecisionLogic.
> - Remove AudioRepetition and AlternativePlc operations, since they can
> no longer be reached.
>
> Bug: webrtc:9421
> Change-Id: I651458e9c1931a99f3b07e242817d303bac119df
> Reviewed-on: https://webrtc-review.googlesource.com/84123
> Commit-Queue: Henrik Lundin <henrik.lundin@webrtc.org>
> Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
> Reviewed-by: Minyue Li <minyue@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#23704}
Bug: webrtc:9421
Change-Id: Ice351b635788167f2971b26470f73a5e5fa1a240
Reviewed-on: https://webrtc-review.googlesource.com/86543
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Commit-Queue: Henrik Lundin <henrik.lundin@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23799}
fft.c is third party library and have to be moved to proper third_party
directory. So this CL will extract it to separate gn target to be able
then to move it to proper location.
Bug: webrtc:8366
Change-Id: I228ebab3c821aa7095f7aa460c23c2ea0fb98f01
Reviewed-on: https://webrtc-review.googlesource.com/85640
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Commit-Queue: Artem Titov <titovartem@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23753}
This reverts commit 80c4cca491.
Reason for revert: Breaks downstream tests.
Original change's description:
> NetEq: Deprecate playout modes Fax, Off and Streaming
>
> The playout modes other than Normal have not been reachable for a long
> time, other than through tests. It is time to deprecate them.
>
> The only meaningful use was that Fax mode was sometimes set from
> tests, in order to avoid time-stretching operations (accelerate and
> pre-emptive expand) from messing with the test results. With this CL,
> a new config is added instead, which lets the user specify exactly
> this: don't do time-stretching.
>
> As a result of Fax and Off modes being removed, the following code
> clean-up was done:
> - Fold DecisionLogicNormal into DecisionLogic.
> - Remove AudioRepetition and AlternativePlc operations, since they can
> no longer be reached.
>
> Bug: webrtc:9421
> Change-Id: I651458e9c1931a99f3b07e242817d303bac119df
> Reviewed-on: https://webrtc-review.googlesource.com/84123
> Commit-Queue: Henrik Lundin <henrik.lundin@webrtc.org>
> Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
> Reviewed-by: Minyue Li <minyue@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#23704}
TBR=henrik.lundin@webrtc.org,ivoc@webrtc.org,minyue@webrtc.org
Change-Id: I555aae8850fc4ac1ea919bfa72c11b5218066f30
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: webrtc:9421
Reviewed-on: https://webrtc-review.googlesource.com/84680
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Commit-Queue: Henrik Lundin <henrik.lundin@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23706}
The playout modes other than Normal have not been reachable for a long
time, other than through tests. It is time to deprecate them.
The only meaningful use was that Fax mode was sometimes set from
tests, in order to avoid time-stretching operations (accelerate and
pre-emptive expand) from messing with the test results. With this CL,
a new config is added instead, which lets the user specify exactly
this: don't do time-stretching.
As a result of Fax and Off modes being removed, the following code
clean-up was done:
- Fold DecisionLogicNormal into DecisionLogic.
- Remove AudioRepetition and AlternativePlc operations, since they can
no longer be reached.
Bug: webrtc:9421
Change-Id: I651458e9c1931a99f3b07e242817d303bac119df
Reviewed-on: https://webrtc-review.googlesource.com/84123
Commit-Queue: Henrik Lundin <henrik.lundin@webrtc.org>
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Reviewed-by: Minyue Li <minyue@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23704}
By removing it we can in turn (next CL) get rid of RTPTypeHeader, which is a
union that cause some problems.
Bug: none
Change-Id: I9246ecbfe2c8b7eda27497cccbc5f438958b64bf
Reviewed-on: https://webrtc-review.googlesource.com/83985
Reviewed-by: Stefan Holmer <stefan@webrtc.org>
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Commit-Queue: Philip Eliasson <philipel@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23666}
Running clang-format with chromium's style guide.
The goal is n-fold:
* providing consistency and readability (that's what code guidelines are for)
* preventing noise with presubmit checks and git cl format
* building on the previous point: making it easier to automatically fix format issues
* you name it
Please consider using git-hyper-blame to ignore this commit.
Bug: webrtc:9340
Change-Id: I694567c4cdf8cee2860958cfe82bfaf25848bb87
Reviewed-on: https://webrtc-review.googlesource.com/81185
Reviewed-by: Patrik Höglund <phoglund@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23660}
This is a no-op change because rtc::Optional is an alias to absl::optional
This CL generated by running script with parameter 'modules/audio_coding'
find $@ -type f \( -name \*.h -o -name \*.cc \) \
-exec sed -i 's|rtc::Optional|absl::optional|g' {} \+ \
-exec sed -i 's|rtc::nullopt|absl::nullopt|g' {} \+ \
-exec sed -i 's|#include "api/optional.h"|#include "absl/types/optional.h"|' {} \+
find $@ -type f -name BUILD.gn \
-exec sed -r -i 's|"[\./api]*:optional"|"//third_party/abseil-cpp/absl/types:optional"|' {} \+;
git cl format
Bug: webrtc:9078
Change-Id: Ic980ee605148fdb160666d4aa03cc87175e48fe8
Reviewed-on: https://webrtc-review.googlesource.com/84130
Reviewed-by: Oskar Sundbom <ossu@webrtc.org>
Commit-Queue: Danil Chapovalov <danilchap@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23659}
This test is so old, it used to be interactive with an automated mode
bolted on to the side. That automatic mode is the only one that's used
nowadays.
Bug: webrtc:8396
Change-Id: I3b473f53ff6afa363b9691e8471a5754f46d3d3f
Reviewed-on: https://webrtc-review.googlesource.com/83583
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Commit-Queue: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23620}
It appears to have been created in mid-2013, and hasn't been changed
since except to keep the compiler happy when surrounding code changed.
It crashes when I try to run it without arguments, and no one
remembers how to use it.
Bug: webrtc:8396
Change-Id: I2eae36cf468f28c5bf05c85e6a3aaeebc48a1ffc
Reviewed-on: https://webrtc-review.googlesource.com/83581
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Commit-Queue: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23618}
Since it isn't being run by the bots, it has bit rotted; when I try to
run it manually, it fails with a long list of error messages:
Error Calling API in file ../../modules/audio_coding/test/APITest.cc at line 995
Error Calling API in file ../../modules/audio_coding/test/APITest.cc at line 996
>>> Error Enabling VAD <<<
Error Calling API in file ../../modules/audio_coding/test/APITest.cc at line 995
Error Calling API in file ../../modules/audio_coding/test/APITest.cc at line 996
>>> Error Enabling DTX <<<
>>> Error Enabling VAD <<<
Error Calling API in file ../../modules/audio_coding/test/APITest.cc at line 995
Error Calling API in file ../../modules/audio_coding/test/APITest.cc at line 996
>>> Error Enabling VAD <<<
Error Calling API in file ../../modules/audio_coding/test/APITest.cc at line 995
Error Calling API in file ../../modules/audio_coding/test/APITest.cc at line 996
Error Calling API in file ../../modules/audio_coding/test/APITest.cc at line 985
...and so on.
Bug: webrtc:8396
Change-Id: Id8f1e01a751b4bb3527702b7b7a4986ce0abb378
Reviewed-on: https://webrtc-review.googlesource.com/81745
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Commit-Queue: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23542}
It's always been there, and there's no security risk.
Bug: chromium:843477
Change-Id: I6121943f23b477300cf60ffc4858ef0ab43466dc
Reviewed-on: https://webrtc-review.googlesource.com/78782
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Commit-Queue: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23393}
This CL implements a fix behind a field trial for a NetEq issue. NetEq restarts audio too quickly after a buffer underrun, which can quickly lead to another underrun in some circumstances. The fix changes NetEq's behavior to wait with restarting playback until sufficient audio is buffered.
Bug: webrtc:9289
Change-Id: I5968c9478ce8d84caf77f00b8d0a39156b47fc8d
Reviewed-on: https://webrtc-review.googlesource.com/77423
Reviewed-by: Minyue Li <minyue@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Commit-Queue: Ivo Creusen <ivoc@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23347}
NetEq tapers down the audio produced through loss concealment when the
expansion has been going on for some time. When the audio packets starts
coming in again, there is a ramp-up that happens. This ramp-up could
before this change extend over more than one 10 ms block, which made
keeping track of the scaling factor necessary. With this change, we make
this ramp-up quicker in the rare cases when it lasted more than 10 ms,
so that it always ramps up to 100% within one block. This way, we can
remove the mute_factor_array.
This change breaks bit-exactness, but careful listening could not reveal
an audible difference.
This change is a part of a larger refactoring of NetEq's PLC code.
Bug: webrtc:9180
Change-Id: I4c513ce3ed8d66f9beec2abfb1f0c7ffaac7a21e
Reviewed-on: https://webrtc-review.googlesource.com/77180
Commit-Queue: Henrik Lundin <henrik.lundin@webrtc.org>
Reviewed-by: Minyue Li <minyue@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23342}
Instead of checking for an exact bitrate check that the bitrate is between
the min and max values.
Also relax a threshold in a bandwith adaptation test.
Bug: webrtc:9280
Change-Id: I465d785a53759f73242198ee1ccd7da1a26c48b7
Reviewed-on: https://webrtc-review.googlesource.com/78041
Commit-Queue: Gustaf Ullberg <gustaf@webrtc.org>
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23330}
The overflow currently does not cause any problems, but it has been
found that it can cause crashes after a refactoring that is coming in
the near future.
Bug: webrtc:9180
Change-Id: Ia2c4e545c062c4f8ad13cbc47b8796c6e8a4e906
Reviewed-on: https://webrtc-review.googlesource.com/77667
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Commit-Queue: Henrik Lundin <henrik.lundin@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23327}
This is a reland of 79ded653fe
Original change's description:
> Update expected bitrate in Opus tests
>
> Upstream changes to Opus DTX behavior changes the bitrates of Opus. This
> CL re-enables recently disabled unittests and updates the expected bitrates.
>
> Bug: webrtc:9280
> Change-Id: I668a0b6a8b82cbbb70d795db4546cb5469266bf2
> Reviewed-on: https://webrtc-review.googlesource.com/77766
> Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
> Commit-Queue: Gustaf Ullberg <gustaf@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#23306}
TBR=henrik.lundin@webrtc.org
Bug: webrtc:9280
Change-Id: I6bfcd1c5e1d5298543024a0faa6a695026434df3
Reviewed-on: https://webrtc-review.googlesource.com/77980
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Reviewed-by: Gustaf Ullberg <gustaf@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23318}
This reverts commit 79ded653fe.
Reason for revert: Different repos have different Opus
Original change's description:
> Update expected bitrate in Opus tests
>
> Upstream changes to Opus DTX behavior changes the bitrates of Opus. This
> CL re-enables recently disabled unittests and updates the expected bitrates.
>
> Bug: webrtc:9280
> Change-Id: I668a0b6a8b82cbbb70d795db4546cb5469266bf2
> Reviewed-on: https://webrtc-review.googlesource.com/77766
> Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
> Commit-Queue: Gustaf Ullberg <gustaf@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#23306}
TBR=henrik.lundin@webrtc.org,gustaf@webrtc.org
Change-Id: I3c18db2d6052c4049d836c3e595b00189aebcbc8
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: webrtc:9280
Reviewed-on: https://webrtc-review.googlesource.com/77800
Reviewed-by: Gustaf Ullberg <gustaf@webrtc.org>
Commit-Queue: Gustaf Ullberg <gustaf@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23307}
Upstream changes to Opus DTX behavior changes the bitrates of Opus. This
CL re-enables recently disabled unittests and updates the expected bitrates.
Bug: webrtc:9280
Change-Id: I668a0b6a8b82cbbb70d795db4546cb5469266bf2
Reviewed-on: https://webrtc-review.googlesource.com/77766
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Commit-Queue: Gustaf Ullberg <gustaf@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23306}
In order to roll the new version of Opus in WebRTC, this CL disables
some tests that will fail because of [1].
They will be re-enabled and fixed as soon as the new Opus revision is
rolled.
[1] - https://chromium-review.googlesource.com/1061499TBR=henrik.lundin@webrtc.org
Bug: webrtc:9280
Change-Id: I84870ced66d554f75c2d093dac8103ad7860cae5
Reviewed-on: https://webrtc-review.googlesource.com/77640
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Gustaf Ullberg <gustaf@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23293}
The current implementation carefully shifts down the energy so as not to overflow.
The fuzzer audio_decoder_ilbc_fuzzer found an integer overflow anyway.
The energy is only used for a threshold check.
This fix stops the energy computation when the threshold is reached, before it can overflow.
Bug: chromium:837922
Change-Id: I45e84d2d271a37e6476b08433a2cbd5a8f6e6f26
Reviewed-on: https://webrtc-review.googlesource.com/76122
Commit-Queue: Sam Zackrisson <saza@webrtc.org>
Reviewed-by: Minyue Li <minyue@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23242}
A bug was introduced to NetEq RTP player in a recent CL:
https://webrtc-review.googlesource.com/c/src/+/69806
This is to fix it.
Bug: webrtc:9147
Change-Id: I949fd6b220d7c7f08c6e2940468232d1d955a3dc
Reviewed-on: https://webrtc-review.googlesource.com/75321
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Commit-Queue: Minyue Li <minyue@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23181}
This change adds flags and default values for two more RTP header
extensions: VideoContentType and VideoTiming.
This will silence a number of annoying warnings when running with
application logs.
Bug: none
Change-Id: I9bb01ea2519813d3c47553ecff384141fbede23e
Reviewed-on: https://webrtc-review.googlesource.com/75300
Reviewed-by: Minyue Li <minyue@webrtc.org>
Commit-Queue: Henrik Lundin <henrik.lundin@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23178}