1174 Commits

Author SHA1 Message Date
Tommi
d44c077dce Revert of Safe numeric library: base/numerics (copied from Chromium) (patchset #11 id:250001 of https://codereview.webrtc.org/1753293002/ )
Reason for revert:
Looks like the Chrome iOS build is broken because of these two changes.  So I'm going to have to revert.  Here's the error:

https://build.chromium.org/p/tryserver.chromium.mac/builders/ios_rel_device_ninja/builds/185624/steps/compile/logs/stdio

FAILED: rm -f arch/libsafe_numerics.arm64.a && ./gyp-mac-tool filter-libtool libtool  -static -o arch/libsafe_numerics.arm64.a
error: /Applications/Xcode7.0.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/libtool: no files specified
Usage: /Applications/Xcode7.0.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/libtool -static [-] file [...] [-filelist listfile[,dirname]] [-arch_only arch] [-sacLT] [-no_warning_for_no_symbols]
Usage: /Applications/Xcode7.0.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/libtool -dynamic [-] file [...] [-filelist listfile[,dirname]] [-arch_only arch] [-o output] [-install_name name] [-compatibility_version #] [-current_version #] [-seg1addr 0x#] [-segs_read_only_addr 0x#] [-segs_read_write_addr 0x#] [-seg_addr_table <filename>] [-seg_addr_table_filename <file_system_path>] [-all_load] [-noall_load]
FAILED: rm -f arch/libsafe_numerics.armv7.a && ./gyp-mac-tool filter-libtool libtool  -static -o arch/libsafe_numerics.armv7.a
error: /Applications/Xcode7.0.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/libtool: no files specified
Usage: /Applications/Xcode7.0.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/libtool -static [-] file [...] [-filelist listfile[,dirname]] [-arch_only arch] [-sacLT] [-no_warning_for_no_symbols]
Usage: /Applications/Xcode7.0.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/libtool -dynamic [-] file [...] [-filelist listfile[,dirname]] [-arch_only arch] [-o output] [-install_name name] [-compatibility_version #] [-current_version #] [-seg1addr 0x#] [-segs_read_only_addr 0x#] [-segs_read_write_addr 0x#] [-seg_addr_table <filename>] [-seg_addr_table_filename <file_system_path>] [-all_load] [-noall_load]
ninja: build stopped: subcommand failed.

Original issue's description:
> Safe numeric library added: base/numerics (copied from Chromium)
>
> This copies the contents (unittest excluded) of base/numerics in
> chromium to base/numerics in webrtc. Files added:
> - safe_conversions.h
> - safe_conversions_impl.h
> - safe_math.h
> - safe_math_impl.h
>
> A really old version of safe_conversions[_impl].h previously existed in
> base/, this has been deleted and sources using it have been updated
> to include the new base/numerics/safe_converions.h.
>
> This CL also adds a DEPS file to webrtc/base.
>
> NOPRESUBMIT=True
> BUG=webrtc:5548, webrtc:5623
>
> Committed: https://crrev.com/de1c81b2d2196be611674aa6019b9db3a9329042
> Cr-Commit-Position: refs/heads/master@{#11907}

TBR=kjellander@webrtc.org,kwiberg@webrtc.org,tina.legrand@webrtc.org,hbos@webrtc.org
# Not skipping CQ checks because original CL landed more than 1 days ago.
BUG=webrtc:5548, webrtc:5623

Review URL: https://codereview.webrtc.org/1792613002 .

Cr-Commit-Position: refs/heads/master@{#11965}
2016-03-12 01:12:40 +00:00
henrik.lundin
d72595eeea Fix NetEq performance test regression
The test code created an AudioBuffer object inside the work loop. This
turned out to be expensive, since the AudioBuffer ctor implicitly
called memset on all of the audio data array. The obvious remedy is to
create the buffer outside of the loop. This does not have any impact
apart from the performance boost, since the output data from NetEq is
not even considered in the test.

BUG=chromium:592907,webrtc:5647
TBR=ivoc@webrtc.org
NOTRY=true

Review URL: https://codereview.webrtc.org/1782803002

Cr-Commit-Position: refs/heads/master@{#11940}
2016-03-10 10:26:36 +00:00
solenberg
3ecb5c8698 Revert of - Clean up unused voice engine DTMF code. (patchset #4 id:60001 of https://codereview.webrtc.org/1722253002/ )
Reason for revert:
Breaks Chromium FYI bots for Android. E.g. https://build.chromium.org/p/chromium.webrtc.fyi/builders/Android%20Tests%20%28dbg%29%20%28K%20Nexus5%29/builds/4486/steps/content_browsertests/logs/stdio

Original issue's description:
> - Clean up unused voice engine DTMF code following removal of VoEDtmf APIs.
> - Use better types in AudioSendStream::SendTelephoneEvent() and related methods.
>
> BUG=webrtc:4690
>
> Committed: https://crrev.com/8886c816582a7c6190c5429222cb8096fca302a6
> Cr-Commit-Position: refs/heads/master@{#11927}

TBR=tina.legrand@webrtc.org,henrik.lundin@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=webrtc:4690

Review URL: https://codereview.webrtc.org/1776243003

Cr-Commit-Position: refs/heads/master@{#11930}
2016-03-09 15:32:05 +00:00
solenberg
8886c81658 - Clean up unused voice engine DTMF code following removal of VoEDtmf APIs.
- Use better types in AudioSendStream::SendTelephoneEvent() and related methods.

BUG=webrtc:4690

Review URL: https://codereview.webrtc.org/1722253002

Cr-Commit-Position: refs/heads/master@{#11927}
2016-03-09 11:32:53 +00:00
kwiberg
6030a129c0 Pass ownership of external encoders to the ACM
We want this because otherwise the ACM uses its mutex to protect an
encoder that's owned by someone else. That someone else may easily
slip up and delete or otherwise touch the encoder before making sure
that the ACM has stopped using it, bypassing the lock.

BUG=webrtc:5028

Review URL: https://codereview.webrtc.org/1702943002

Cr-Commit-Position: refs/heads/master@{#11909}
2016-03-08 14:01:37 +00:00
henrik.lundin
bc89de3bca Adding a namespace comment
This was pointed out in https://codereview.webrtc.org/1772583002/.

BUG=webrtc:5607 NOTRY=true
TBR=kwiberg@webrtc.org

Review URL: https://codereview.webrtc.org/1774933002

Cr-Commit-Position: refs/heads/master@{#11908}
2016-03-08 13:20:18 +00:00
hbos
de1c81b2d2 Safe numeric library added: base/numerics (copied from Chromium)
This copies the contents (unittest excluded) of base/numerics in
chromium to base/numerics in webrtc. Files added:
- safe_conversions.h
- safe_conversions_impl.h
- safe_math.h
- safe_math_impl.h

A really old version of safe_conversions[_impl].h previously existed in
base/, this has been deleted and sources using it have been updated
to include the new base/numerics/safe_converions.h.

This CL also adds a DEPS file to webrtc/base.

NOPRESUBMIT=True
BUG=webrtc:5548, webrtc:5623

Review URL: https://codereview.webrtc.org/1753293002

Cr-Commit-Position: refs/heads/master@{#11907}
2016-03-08 12:46:07 +00:00
henrik.lundin
55480f5efa Remove the type parameter to NetEq::GetAudio
The type is included in the AudioFrame output parameter.

Rename the type NetEqOutputType to just OutputType, since it is now
internal to NetEq.

BUG=webrtc:5607

Review URL: https://codereview.webrtc.org/1769883002

Cr-Commit-Position: refs/heads/master@{#11903}
2016-03-08 10:38:02 +00:00
henrik.lundin
500c04bc86 Delete VAD methods from AcmReceiver and move functionality inside NetEq
This change essentially does two things:

1. Remove the VAD-related methods from AcmReceiver. These are
EnableVad(), DisableVad(), and vad_enabled(). None of them were used
outside of unit tests.

2. Move the functionality to set AudioFrame::speech_type_ and
AudioFrame::vad_activity_ inside NetEq. This was previously done in
AcmReceiver, but based on information inherently owned by NetEq.

With the change in 2, NetEq's GetAudio interface can be simplified by
removing the output type parameter. This will be done in a follow-up
CL.

BUG=webrtc:5607

Review URL: https://codereview.webrtc.org/1772583002

Cr-Commit-Position: refs/heads/master@{#11902}
2016-03-08 10:36:07 +00:00
asapersson
a2c58e2198 Switch to use new implementation in metrics.h for gathering statistics.
Sparse macro replaced for all audio histograms that have a constant name.

BUG=webrtc:5283

Review URL: https://codereview.webrtc.org/1762863003

Cr-Commit-Position: refs/heads/master@{#11885}
2016-03-07 09:53:08 +00:00
henrik.lundin
6d8e011b64 Change NetEq::GetAudio to use AudioFrame
With this change, NetEq now uses AudioFrame as output type, like the
surrounding functions in ACM and VoiceEngine already do.

The computational savings is probably slim, since one memcpy is
removed while another one is added (both in AcmReceiver::GetAudio).

More simplifications and clean-up will be done in
AcmReceiver::GetAudio in future CLs.

BUG=webrtc:5607

Review URL: https://codereview.webrtc.org/1750353002

Cr-Commit-Position: refs/heads/master@{#11874}
2016-03-04 18:34:26 +00:00
ossu
4f43fcfd49 Renamed new EncodeInternal to EncodeImpl to ensure proper backwards compatibility.
Renamed the new variant of EncodeInternal to EncodeImpl, so that
subclasses implementing one of the EncodeInternal don't need to
explicitly contain 'using AudioEncoder::EncodeInternal' to avoid their
implementation hiding the other variant of EncodeInternal. This causes
a warning (treated as an error) when building using GCC.

Review URL: https://codereview.webrtc.org/1764583003

Cr-Commit-Position: refs/heads/master@{#11868}
2016-03-04 08:54:38 +00:00
henrik.lundin
0023fdffd0 Remove the ID from AcmReceiver
This is an artifact from the past, and is no longer used.

R=ivoc@webrtc.org

Review URL: https://codereview.webrtc.org/1764623002

Cr-Commit-Position: refs/heads/master@{#11866}
2016-03-04 07:05:45 +00:00
ossu
10a029e952 Changed AudioEncoder::Encode to take an rtc::Buffer* instead of uint8_t* and a maximum size.
For backwards compatibility, I've added kept the old interface to
Encode() and EncodeInternal and created default implementations of both
variants of EncodeInternal(), each calling the other. At least one of
the variants must be implemented in a subclass or we'll run out of stack
and explode. Would be nice if we could catch that before runtime. :/

The new interface to EncodeInternal() is protected, since it should
never be called from the outside.

Was unable to mark the old EncodeInternal() as RTC_DEPRECATED, since the
default implementaion of the new variant needs to call it to work around
old implementations. The old Encode() variant is deprecated, at least.

Added a test for backwards compatibility in audio_encoder_unittest.cc.
For the added test I broke out MockEncodeHelper from
audio_encoder_copy_red_unittest.cc and renamed it MockAudioEncoderHelper.

Review URL: https://codereview.webrtc.org/1725143003

Cr-Commit-Position: refs/heads/master@{#11823}
2016-03-01 08:41:39 +00:00
minyuel
7e937e951c Remove workaround for Opus DTX noise pumping issue.
A workaround for Opus DTX noise pumping issue was made according upon this
https://codereview.webrtc.org/1422213003

Recently, Opus has fixed this problem internally, and hence the workaround is not needed any longer.

This CL removes this workaround.

BUG=586175
R=flim@webrtc.org, tina.legrand@webrtc.org

Review URL: https://codereview.webrtc.org/1715423002 .

Cr-Commit-Position: refs/heads/master@{#11805}
2016-02-29 09:24:25 +00:00
kwiberg
806706875d iSAC entropy coder: Avoid signed integer overflow
By doing an unsigned instead of a signed addition, we get the exact
same machine code (in non-UBSan builds), but no longer trigger
undefined behavior since unsigned overflow is defined behavior.

BUG=webrtc:5485

Review URL: https://codereview.webrtc.org/1734883003

Cr-Commit-Position: refs/heads/master@{#11776}
2016-02-26 10:52:14 +00:00
minyue
58e08cbea8 Reset indexer upon initialization in AudioLoop.
The array is reset in Init() but not the indexer. This makes the start point undefined after Init() for re-initializing an AudioLoop. This can be fixed.

BUG=

Review URL: https://codereview.webrtc.org/1727353002

Cr-Commit-Position: refs/heads/master@{#11739}
2016-02-24 11:49:23 +00:00
kwiberg
b7261fd3ae iSAC float: Check for end of input buffer while decoding
Previously, we relied on the encoded stream to come to an end before
the end of the buffer. This is a bad idea, since it is possible to
craft a stream that fills the buffer while decoding to less than the
expected amount of data; without the new checks introduced here, this
causes the decoder to read past the end of the input buffer.

BUG=chromium:582471, chromium:587852

Review URL: https://codereview.webrtc.org/1721593004

Cr-Commit-Position: refs/heads/master@{#11734}
2016-02-24 09:34:33 +00:00
kjellander
0206000a66 iOS: Add resource files for tests and implement OutputPath
With this change the following tests have been successfully
passing in the iOS Simulator for iPhone 5 and iOS 9:
* audio_decoder_unittests
* common_video_unittests
* modules_tests
* rtc_api_objc_tests
* rtc_pc_unittests
* system_wrappers_unittests
* voice_engine_unittests

The modules_unittests and common_audio_unittests are
handled in https://codereview.webrtc.org/1698033002/

BUG=webrtc:4755
NOTRY=True

Review URL: https://codereview.webrtc.org/1694353003

Cr-Commit-Position: refs/heads/master@{#11646}
2016-02-17 06:06:17 +00:00
henrik.lundin
2c38c20e7b Fix out-of-buffer write in iLBC
In some cases, the decoder can write outside of an allocated array. See
the new comment in the code for more details.

BUG=chromium:568885, webrtc:5305

Review URL: https://codereview.webrtc.org/1704463002

Cr-Commit-Position: refs/heads/master@{#11641}
2016-02-16 18:01:57 +00:00
henrik.lundin
ee31f0a7d5 Fix out-of-buffer read in iLBC
In some cases, the decoder can read outside of an allocated array. See
the new comment in the code for more details.

BUG=chromium:568889, webrtc:5305

Review URL: https://codereview.webrtc.org/1700973002

Cr-Commit-Position: refs/heads/master@{#11637}
2016-02-16 16:42:15 +00:00
kwiberg
16c5a96630 Replace scoped_ptr with unique_ptr in webrtc/modules/audio_coding/
BUG=webrtc:5520

Review URL: https://codereview.webrtc.org/1694073002

Cr-Commit-Position: refs/heads/master@{#11622}
2016-02-15 10:27:34 +00:00
kwiberg
3747838afb Replace scoped_ptr with unique_ptr in webrtc/modules/audio_coding/test/
BUG=webrtc:5520

Review URL: https://codereview.webrtc.org/1695763004

Cr-Commit-Position: refs/heads/master@{#11618}
2016-02-15 04:41:04 +00:00
kwiberg
2d0c33277c Replace scoped_ptr with unique_ptr in webrtc/modules/audio_coding/neteq/
BUG=webrtc:5520

Review URL: https://codereview.webrtc.org/1697823002

Cr-Commit-Position: refs/heads/master@{#11616}
2016-02-14 17:28:39 +00:00
kwiberg
91d9756bc6 Replace scoped_ptr with unique_ptr in webrtc/modules/audio_coding/codecs/
BUG=webrtc:5520

Review URL: https://codereview.webrtc.org/1696853004

Cr-Commit-Position: refs/heads/master@{#11613}
2016-02-14 09:10:08 +00:00
henrik.lundin
07c51e3f79 Fix two UBSan warnings in NetEq
Both were related to very large jumps in RTP timestamps.

BUG=webrtc:5488

Review URL: https://codereview.webrtc.org/1685103002

Cr-Commit-Position: refs/heads/master@{#11569}
2016-02-11 11:35:51 +00:00
henrik.lundin
6608d9a1aa NetEq: Fix a negative shift value
In some rare occations (very low energy signal), a shift value happened
to be negative. This is now fixed by using the WEBRTC_SPL_SHIFT_W32,
which in essence checks the sign of the number of shifts and performs a
right or left shift accordingly.

The fix reverts to how the code was written in old NetEq; see
4d363ae305/webrtc/modules/audio_coding/neteq/normal.c (165).

BUG=webrtc:5490

Review URL: https://codereview.webrtc.org/1675293002

Cr-Commit-Position: refs/heads/master@{#11546}
2016-02-10 10:47:56 +00:00
kjellander
4bba35f735 Switch third_party/gflags to use updated GitHub repo.
This pulls in several fixes and gets Visual Studio 2015 support.
The new repo is located at https://github.com/gflags/gflags
which is mirrored in Chrome infrastructure at
https://chromium.googlesource.com/external/github.com/gflags/gflags

New configuration headers were generated according to README.webrtc
on Windows and Linux. I verified the Linux generated ones are working
on Mac. The generating headers on Mac are identical with only a minor
difference (an __unused attribute) that doesn't effect the build.

BUG=webrtc:5185
NOTRY=True
NOPRESUBMIT=True
TESTED=Successfully ran:
out/Release/video_quality_measurement --input_filename=resources/foreman_cif.yuv  --width=352 --height=288
to verify flags are still being parsed properly.
I also ran the compile trybots and the baremetal bots
(since they run tests that have gflags flags).

Review URL: https://codereview.webrtc.org/1679263002

Cr-Commit-Position: refs/heads/master@{#11539}
2016-02-09 14:47:47 +00:00
henrik.lundin
e594213a2b Fix div-by-0 in NetEq's StatisticsCalculator
If a StatisticsCalculator::PeriodicUmaAverage object was created and
then deleted without any samples being logged, the destructor would call
the Metric() method, which calculated sum_/counter_. However, with no
samples logged, counter_ is 0.

This was found and verified using UBSan tests; see the bug for more info.

BUG=webrtc:5490
R=ivoc@webrtc.org

Review URL: https://codereview.webrtc.org/1678773003

Cr-Commit-Position: refs/heads/master@{#11534}
2016-02-09 08:36:02 +00:00
kjellander
988d31eb9b Move gtest_prod_util.h out of webrtc/test tree.
This is needed because the target is defined in webrtc/common.gyp
and its current location crosses package boundaries when generating
projects for some build systems.

NOTRY=True

Review URL: https://codereview.webrtc.org/1665603003

Cr-Commit-Position: refs/heads/master@{#11496}
2016-02-05 08:23:57 +00:00
kjellander
c3a0983d4b Roll chromium_revision a8e5140..c6076f2 (372922:372974) incl. update to Opus v.1.1.2
Includes updates to tests for Opus v.1.1.2, reveiwed in
https://codereview.webrtc.org/1629413002/

Change log: a8e5140..c6076f2
Full diff: a8e5140..c6076f2

Changed dependencies:
* src/third_party/catapult: 471db30..d4d48e6
* src/third_party/opus/src: cae6961..655cc54
DEPS diff: a8e5140..c6076f2/DEPS

No update to Clang.

BUG=chromium:580524
TBR=

Review URL: https://codereview.webrtc.org/1657343002

Cr-Commit-Position: refs/heads/master@{#11464}
2016-02-02 21:18:42 +00:00
conceptgenesis
3f70562bbb Fix WebRtc ninja x86 build using Visual Studio 2015 (set GYP_MSVS_VERSION=2015).
Visual Studio 2015 balks at the implicit truncation of values. Easily fixed with an explicit cast.

Fixed redefinition of CLOCKS_PER_SEC when using Visual Studio 2015 and the Windows 10 SDK. CLOCKS_PER_SEC is also defined in "<WIN10 SDK DIR>\include\10.0.10240.0\ucrt\time.h" and also has the value of 1000

Hiding snprintf definition if building with Visual Studio 2015

Fixed C4573 compiler complaint in audio_processing_impl_locking_unittest.cc.

BUG=webrtc:5183

Review URL: https://codereview.webrtc.org/1412653006

Cr-Commit-Position: refs/heads/master@{#11434}
2016-01-30 22:40:52 +00:00
kwiberg
83277131b1 AudioCodingModuleImpl: Put CodecManager and Rent-A-Codec in a separate struct
This will make it easier for future CLs to make them optional.

BUG=webrtc:5028

Review URL: https://codereview.webrtc.org/1625363002

Cr-Commit-Position: refs/heads/master@{#11381}
2016-01-26 14:06:20 +00:00
kwiberg
6a07f12e95 AudioCodingModuleImpl: Initialize encoder_stack_ to nullptr
This should have been done in commit 11340, but it was left out by
mistake.

BUG=webrtc:5028

Review URL: https://codereview.webrtc.org/1631443002

Cr-Commit-Position: refs/heads/master@{#11378}
2016-01-26 11:28:57 +00:00
pbos
5ad935cb56 Remove mutable from rtc::CriticalSection members.
rtc::CriticalSection is now lockable from const methods and no longer
need to remain mutable.

BUG=
R=tommi@webrtc.org

Review URL: https://codereview.webrtc.org/1613643004

Cr-Commit-Position: refs/heads/master@{#11367}
2016-01-25 11:52:53 +00:00
henrik.lundin
fea3dd83fc Fix a bug in InputAudioFile::Read
When the file was rewound, the remaining audio read was inserted at
the start of the destination array, not where the first reading
attempt ended.

R=ivoc@webrtc.org

Review URL: https://codereview.webrtc.org/1612053002

Cr-Commit-Position: refs/heads/master@{#11343}
2016-01-21 16:20:01 +00:00
kwiberg
32be07bc36 Remove RentACodec::GetEncoderStack
Callers can just remember the return value of
RentACodec::RentEncoderStack instead.

BUG=webrtc:5028

Review URL: https://codereview.webrtc.org/1612713002

Cr-Commit-Position: refs/heads/master@{#11340}
2016-01-21 15:10:04 +00:00
ivoc
72c08edced Reenables several NetEq unittests on android.
Several unittests were disabled on android, this CL will reenable them. One of
the tests was accidentally disabled on all platforms, and now no longer gives a
bitexact result.

BUG=webrtc:3343,webrtc:5349

Review URL: https://codereview.webrtc.org/1532903002

Cr-Commit-Position: refs/heads/master@{#11323}
2016-01-20 15:26:28 +00:00
Tommi
9090e0b147 Switch CriticalSectionWrapper->rtc::CriticalSection in modules/audio_coding.
This is a part of cleaning up CriticalSectionWrapper in general.

BUG=
R=henrik.lundin@webrtc.org

Review URL: https://codereview.webrtc.org/1610073003 .

Cr-Commit-Position: refs/heads/master@{#11319}
2016-01-20 12:39:45 +00:00
Tommi
ee5a309f12 Make CriticalSectionWrapper non-virtual.
There's no need for this class to have a vtable since there exists only a single implementation (per platform).  It's also not good for performance.

BUG=
R=pbos@webrtc.org

Review URL: https://codereview.webrtc.org/1601743004 .

Cr-Commit-Position: refs/heads/master@{#11306}
2016-01-19 14:42:58 +00:00
kwiberg
0edb05b344 Declare that rent_a_codec depends on the audio codecs
That these declarations were missing was a bug, which apparently
didn't actually cause build problems in either Chromium or WebRTC
standalone. (Presumably, because rent_a_codec was always linked
together with other build targets that did declare such dependencies.)

BUG=webrtc:5435

Review URL: https://codereview.webrtc.org/1607463002

Cr-Commit-Position: refs/heads/master@{#11303}
2016-01-19 13:54:31 +00:00
kwiberg
f8c2baca4e Add a gyp/gn variable for whether to use iLBC or not
BUG=webrtc:5415

Review URL: https://codereview.webrtc.org/1578953003

Cr-Commit-Position: refs/heads/master@{#11291}
2016-01-18 14:38:40 +00:00
Peter Kasting
6955870806 Convert channel counts to size_t.
IIRC, this was originally requested by ajm during review of the other size_t conversions I did over the past year, and I agreed it made sense, but wanted to do it separately since those changes were already gargantuan.

BUG=chromium:81439
TEST=none
R=henrik.lundin@webrtc.org, henrika@webrtc.org, kjellander@webrtc.org, minyue@webrtc.org, perkj@webrtc.org, solenberg@webrtc.org, stefan@webrtc.org, tina.legrand@webrtc.org

Review URL: https://codereview.webrtc.org/1316523002 .

Cr-Commit-Position: refs/heads/master@{#11229}
2016-01-13 00:26:55 +00:00
Henrik Lundin
e84e96e8be NetEq: Fix a typo in a comment
TBR=minyue@webrtc.org
NOTRY=true

Review URL: https://codereview.webrtc.org/1578223003 .

Cr-Commit-Position: refs/heads/master@{#11226}
2016-01-12 15:36:23 +00:00
pkasting
25702cb162 Misc. small cleanups.
* Better param names
* Avoid using negative values for (bogus) placeholder channel counts (mostly in tests).  Since channels will be changing to size_t, negative values will be illegal; it's sufficient to use 0 in these cases.
* Use arraysize()
* Use size_t for counting frames, samples, blocks, buffers, and bytes -- most of these are already size_t in most places, this just fixes some stragglers
* reinterpret_cast<int64_t>(void*) is not necessarily safe; use uintptr_t instead
* Remove unnecessary code, e.g. dead code, needlessly long/repetitive code, or function overrides that exactly match the base definition
* Fix indenting
* Use uint32_t for timestamps (matching how it's already a uint32_t in most places)
* Spelling
* RTC_CHECK_EQ(expected, actual)
* Rewrap
* Use .empty()
* Be more pedantic about matching int/int32_t/
* Remove pointless consts on input parameters to functions
* Add missing sanity checks

All this was found in the course of constructing https://codereview.webrtc.org/1316523002/ , and is being landed separately first.

BUG=none
TEST=none

Review URL: https://codereview.webrtc.org/1534193008

Cr-Commit-Position: refs/heads/master@{#11191}
2016-01-08 21:50:32 +00:00
minyue
49c454e748 Cleaning neteq_unittest resource files.
BUG=webrtc:2692

Review URL: https://codereview.webrtc.org/1563983003

Cr-Commit-Position: refs/heads/master@{#11189}
2016-01-08 19:30:18 +00:00
henrik.lundin
e1ca167217 Add tracing to NetEqImpl::GetAudio
BUG=webrtc:5167
R=pbos@webrtc.org
NOTRY=true

Review URL: https://codereview.webrtc.org/1571693002

Cr-Commit-Position: refs/heads/master@{#11183}
2016-01-08 11:50:14 +00:00
Peter Boström
e2976c87f7 Remove DISABLED_ON_ macros.
Macro incorrectly displays DISABLED_ON_ANDROID in test names for
parameterized tests under --gtest_list_tests, causing tests to be
disabled on all platforms since they contain the DISABLED_ prefix rather
than their expanded variants.

This expands the macro variants to inline if they're disabled or not,
and removes building some tests under configurations where they should
fail, instead of building them but disabling them by default.

The change also removes gtest_disable.h as an unused include from many
other files.

BUG=webrtc:5387, webrtc:5400
R=kjellander@webrtc.org, phoglund@webrtc.org
TBR=henrik.lundin@webrtc.org

Review URL: https://codereview.webrtc.org/1547343002 .

Cr-Commit-Position: refs/heads/master@{#11150}
2016-01-04 21:44:16 +00:00
minyue
93c08b7438 Adding bit exactness test for Opus decoding in NetEq.
Opus has become the mostly used codec in WebRTC. There, however, is no bit exactness test for Opus decoding in NetEq.

The new RTP file is generated by the following steps:
    1. Encode a clean RTP file with Opus
RTPencode resources/audio_coding/speech_mono_32_48kHz.pcm neteq_opus_raw.rtp 960 opus 1

    2. Adding jitter to the clean RTP file
RTPjitter neteq_opus_raw.rtp jitter.dat neteq_opus.rtp
(Note: jitter.dat does not exist in WebRTC resources folder. Check the source code for RTPjitter to know how to define such a file.)

BUG=webrtc:3987
TEST=observed Opus normal decoding and FEC decoding were used, listened to the reference output.

Review URL: https://codereview.webrtc.org/1515113002

Cr-Commit-Position: refs/heads/master@{#11113}
2015-12-22 17:57:47 +00:00
asapersson
53805324c0 Rename RTC_HISTOGRAM_* macros to RTC_HISTOGRAM_*_SPARSE_* to indicate that these are for infrequent updates.
This implementation will be replaced by a faster one and sparse will be removed.

BUG=webrtc:5283

Review URL: https://codereview.webrtc.org/1530913002

Cr-Commit-Position: refs/heads/master@{#11099}
2015-12-21 09:46:25 +00:00