Commit graph

32 commits

Author SHA1 Message Date
Mirko Bonadei
bb547203bf Moving src/webrtc into src/.
In order to eliminate the WebRTC Subtree mirror in Chromium, 
WebRTC is moving the content of the src/webrtc directory up
to the src/ directory.

NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
TBR=tommi@webrtc.org

Bug: chromium:611808
Change-Id: Iac59c5b51b950f174119565bac87955a7994bc38
Reviewed-on: https://webrtc-review.googlesource.com/1560
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Henrik Kjellander <kjellander@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#19845}
2017-09-15 04:25:06 +00:00
oprypin
9b2f20c618 Replace gflags usages with rtc_base/flags in all targets based on test_main
BUG=webrtc:7644

Review-Url: https://codereview.webrtc.org/2995363002
Cr-Commit-Position: refs/heads/master@{#19580}
2017-08-29 12:51:57 +00:00
Edward Lemur
c20978e581 Rename webrtc/base -> webrtc/rtc_base
NOPRESUBMIT=True # cpplint errors that aren't caused by this CL.
NOTRY=True
NOTREECHECKS=True
TBR=kwiberg@webrtc.org, kjellander@webrtc.org

Bug: webrtc:7634
Change-Id: I3cca0fbaa807b563c95979cccd6d1bec32055f36
Reviewed-on: https://chromium-review.googlesource.com/562156
Commit-Queue: Edward Lemur <ehmaldonado@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#18919}
2017-07-06 19:11:40 +00:00
Henrik Kjellander
dca1e09db7 Revert "Update includes for webrtc/{base => rtc_base} rename (1/3)"
This reverts commit c8fa692ec4.

BUG=webrtc:7634
NOTRY=True
NOPRESUBMIT=True

Review-Url: https://codereview.webrtc.org/2964773002 .
Cr-Commit-Position: refs/heads/master@{#18872}
2017-07-01 14:42:25 +00:00
kjellander
c8fa692ec4 Update includes for webrtc/{base => rtc_base} rename (1/3)
I used a command like this to update the paths:
perl -pi -e "s/webrtc\/base/webrtc\/rtc_base/g" `find webrtc/rtc_base -name "*.cc" -o -name "*.h"`

The only manual edit is to add an include of webrtc/rtc_base/checks.h in
webrtc/modules/audio_device/android/opensles_common.h, which likely
was needed due to changed include paths due to 'git cl format'.

BUG=webrtc:7634
NOTRY=True
NOPRESUBMIT=True

Review-Url: https://codereview.webrtc.org/2969653002
Cr-Commit-Position: refs/heads/master@{#18871}
2017-06-30 21:02:00 +00:00
yujo
36b1a5fcec Add mute state field to AudioFrame and switch some callers to use it. Also make AudioFrame::data_ private and instead provide:
const int16_t* data() const;
int16_t* mutable_data();

- data() returns a zeroed static buffer on muted frames (to avoid unnecessary zeroing of the member buffer) and directly returns AudioFrame::data_ on unmuted frames.
- mutable_data(), lazily zeroes AudioFrame::data_ if the frame is currently muted, sets muted=false, and returns AudioFrame::data_.

These accessors serve to "force" callers to be aware of the mute state field, i.e. lazy zeroing is not the primary motivation.

This change only optimizes handling of muted frames where it is somewhat trivial to do so. Other improvements requiring more significant structural changes will come later.

BUG=webrtc:7343
TBR=henrika

Review-Url: https://codereview.webrtc.org/2750783004
Cr-Commit-Position: refs/heads/master@{#18543}
2017-06-12 19:45:32 +00:00
henrik.lundin
246ef3ea0e Change from WebRtcRTPHeader to RTPHeader in NetEq tests and tools
With this CL, all tests and tools under the neteq/ folder are
converted to use RTPHeader instead of WebRtcRTPHeader. WebRtcRTPHeader
has an RTPHeader as a member. None of the other member in
WebRtcRTPHeader where used.

TBR=kjellander@webrtc.org
CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:linux_chromium_compile_rel_ng,linux_chromium_compile_dbg_ng
BUG=webrtc:7467

Review-Url: https://codereview.webrtc.org/2809153002
Cr-Commit-Position: refs/heads/master@{#17845}
2017-04-24 16:14:32 +00:00
Henrik Lundin
70c09bde41 Reland of Change NetEq::InsertPacket to take an RTPHeader (patchset #1 id:1 of https://codereview.webrtc.org/2812933002/ )
Reason for revert:
Downstream roadblock should be cleared by now. Relanding original patch.

Original issue's description:
> Revert of Change NetEq::InsertPacket to take an RTPHeader (patchset #2 id:20001 of https://codereview.webrtc.org/2807273004/ )
>
> Reason for revert:
> Broke downstream dependencies.
>
> Original issue's description:
> > Change NetEq::InsertPacket to take an RTPHeader
> >
> > It used to take a WebRtcRTPHeader as input, which has an RTPHeader as
> > a member. None of the other member in WebRtcRTPHeader where used in
> > NetEq.
> >
> > This CL adapts the production code; tests and tools will be converted
> > in a follow-up CL.
> >
> > BUG=webrtc:7467
> >
> > Review-Url: https://codereview.webrtc.org/2807273004
> > Cr-Commit-Position: refs/heads/master@{#17652}
> > Committed: 4d027576a6
>
> TBR=ivoc@webrtc.org
> # Skipping CQ checks because original CL landed less than 1 days ago.
> NOPRESUBMIT=true
> NOTREECHECKS=true
> NOTRY=true
> BUG=webrtc:7467
>
> Review-Url: https://codereview.webrtc.org/2812933002
> Cr-Commit-Position: refs/heads/master@{#17657}
> Committed: 10d095d4f7

R=ivoc@webrtc.org
# Not skipping CQ checks because original CL landed more than 1 days ago.
CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:linux_chromium_rel_ng
BUG=webrtc:7467

Review-Url: https://codereview.webrtc.org/2835093002 .
Cr-Commit-Position: refs/heads/master@{#17843}
2017-04-24 13:56:57 +00:00
henrik.lundin
10d095d4f7 Revert of Change NetEq::InsertPacket to take an RTPHeader (patchset #2 id:20001 of https://codereview.webrtc.org/2807273004/ )
Reason for revert:
Broke downstream dependencies.

Original issue's description:
> Change NetEq::InsertPacket to take an RTPHeader
>
> It used to take a WebRtcRTPHeader as input, which has an RTPHeader as
> a member. None of the other member in WebRtcRTPHeader where used in
> NetEq.
>
> This CL adapts the production code; tests and tools will be converted
> in a follow-up CL.
>
> BUG=webrtc:7467
>
> Review-Url: https://codereview.webrtc.org/2807273004
> Cr-Commit-Position: refs/heads/master@{#17652}
> Committed: 4d027576a6

TBR=ivoc@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=webrtc:7467

Review-Url: https://codereview.webrtc.org/2812933002
Cr-Commit-Position: refs/heads/master@{#17657}
2017-04-11 14:47:59 +00:00
henrik.lundin
4d027576a6 Change NetEq::InsertPacket to take an RTPHeader
It used to take a WebRtcRTPHeader as input, which has an RTPHeader as
a member. None of the other member in WebRtcRTPHeader where used in
NetEq.

This CL adapts the production code; tests and tools will be converted
in a follow-up CL.

BUG=webrtc:7467

Review-Url: https://codereview.webrtc.org/2807273004
Cr-Commit-Position: refs/heads/master@{#17652}
2017-04-11 13:17:46 +00:00
kwiberg
087bd34d23 Move AudioDecoder and related stuff to the api/ directory
BUG=webrtc:5805, webrtc:6725

Review-Url: https://codereview.webrtc.org/2668523004
Cr-Commit-Position: refs/heads/master@{#16534}
2017-02-10 16:15:44 +00:00
ehmaldonado
1dffc62843 Remove all occurrences of "using std::string".
BUG=webrtc:7104
NOTRY=True

Review-Url: https://codereview.webrtc.org/2675723002
Cr-Commit-Position: refs/heads/master@{#16418}
2017-02-02 16:10:00 +00:00
aleloi
630c6d58d3 Migrated GN target :neteq_opus_quality_test
Migrated GN target :neteq_opus_quality_test from
webrtc/modules/audio_coding/neteq/neteq_tests.gypi

NOTRY=True

BUG=webrtc:6190, webrtc:2692

Review-Url: https://codereview.webrtc.org/2223933004
Cr-Commit-Position: refs/heads/master@{#13701}
2016-08-10 09:11:49 +00:00
ossu
e352578bc8 Moved injection of AudioDecoderFactory into voe::Channel.
Channel's API remains unchanged, but the creation of a BuiltinAudioDecoderFactory is now in Channel. The next step would be to amend Channel's API (through CreateChannel, I believe) to allow an AudioDecoderFactory to be sent along.

BUG=webrtc:5805

Review-Url: https://codereview.webrtc.org/1992763002
Cr-Commit-Position: refs/heads/master@{#12893}
2016-05-25 14:37:47 +00:00
henrik.lundin
7a926812d8 NetEq: Implement muted output
This CL implements the muted output functionality in NetEq. Tests are
added. The feature is currently off by default, and AcmReceiver makes
sure that the muted state is not engaged.

BUG=webrtc:5608

Review-Url: https://codereview.webrtc.org/1965733002
Cr-Commit-Position: refs/heads/master@{#12711}
2016-05-12 20:51:37 +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
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
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
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
4cf61dd116 NetEq: Add codec name and RTP timestamp rate to DecoderInfo
The new fields are default-populated for built-in decoders, but for
external decoders, the name can now be given when registering the
decoder.

BUG=webrtc:3520

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

Cr-Commit-Position: refs/heads/master@{#10952}
2015-12-09 14:21:02 +00:00
kwiberg
ee2bac26dd AcmReceiver::InsertPacket and NetEq::InsertPacket: Take ArrayView arguments
Instead of separate pointer and size arguments.

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

Cr-Commit-Position: refs/heads/master@{#10606}
2015-11-11 18:34:07 +00:00
kwiberg
ee1879ca40 Make an enum class out of NetEqDecoder, and hide the neteq_decoders_ table
This operation was relatively simple, since no one was doing anything
fishy with this enum. A large number of lines had to be changed
because the enum values now live in their own namespace, but this is
arguably worth it since it is now much clearer what sort of constant
they are.

BUG=webrtc:5028

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

Cr-Commit-Position: refs/heads/master@{#10449}
2015-10-29 13:20:33 +00:00
henrikg
91d6edef35 Add RTC_ prefix to (D)CHECKs and related macros.
We must remove dependency on Chromium, i.e. we can't use Chromium's base/logging.h. That means we need to define these macros in WebRTC also when doing Chromium builds. And this causes redefinition.

Alternative solutions:
* Check if we already have defined e.g. CHECK, and don't define them in that case. This makes us depend on include order in Chromium, which is not acceptable.
* Don't allow using the macros in WebRTC headers. Error prone since if someone adds it there by mistake it may compile fine, but later break if a header in added or order is changed in Chromium. That will be confusing and hard to enforce.
* Ensure that headers that are included by an embedder don't include our macros. This would require some heavy refactoring to be maintainable and enforcable.
* Changes in Chromium for this is obviously not an option.

BUG=chromium:468375
NOTRY=true

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

Cr-Commit-Position: refs/heads/master@{#9964}
2015-09-17 07:24:51 +00:00
Peter Kasting
dce40cf804 Update a ton of audio code to use size_t more correctly and in general reduce
use of int16_t/uint16_t.

This is the upshot of a recommendation by henrik.lundin and kwiberg on an original small change ( https://webrtc-codereview.appspot.com/42569004/#ps1 ) to stop using int16_t just because values could fit in it, and is similar in nature to a previous "mass change to use size_t more" ( https://webrtc-codereview.appspot.com/23129004/ ) which also needed to be split up for review but to land all at once, since, like adding "const", such changes tend to cause a lot of transitive effects.

This was be reviewed and approved in pieces:
https://codereview.webrtc.org/1224093003
https://codereview.webrtc.org/1224123002
https://codereview.webrtc.org/1224163002
https://codereview.webrtc.org/1225133003
https://codereview.webrtc.org/1225173002
https://codereview.webrtc.org/1227163003
https://codereview.webrtc.org/1227203003
https://codereview.webrtc.org/1227213002
https://codereview.webrtc.org/1227893002
https://codereview.webrtc.org/1228793004
https://codereview.webrtc.org/1228803003
https://codereview.webrtc.org/1228823002
https://codereview.webrtc.org/1228823003
https://codereview.webrtc.org/1228843002
https://codereview.webrtc.org/1230693002
https://codereview.webrtc.org/1231713002

The change is being landed as TBR to all the folks who reviewed the above.

BUG=chromium:81439
TEST=none
R=andrew@webrtc.org, pbos@webrtc.org
TBR=aluebs, andrew, asapersson, henrika, hlundin, jan.skoglund, kwiberg, minyue, pbos, pthatcher

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

Cr-Commit-Position: refs/heads/master@{#9768}
2015-08-24 21:52:45 +00:00
Minyue Li
f761d10393 Update NetEq Quality Test.
1. move channel number of input file to the base class

2. limit channel number to be 1, since the resampler support only mono at the moment

3. adding a logging function

4. adding more switch to neteq_opus_quality_test

BUG=2692
R=henrik.lundin@webrtc.org

Review URL: https://webrtc-codereview.appspot.com/47239004

Cr-Commit-Position: refs/heads/master@{#9260}
2015-05-22 09:21:58 +00:00
Henrik Lundin
e5ff00a1c6 Add NetEqPcmuQualityTest
This is virtually the same as NetEq{Isac,Opus}QualityTest but for PCMu.

BUG=2692
R=minyue@webrtc.org

Review URL: https://webrtc-codereview.appspot.com/54379004

Cr-Commit-Position: refs/heads/master@{#9176}
2015-05-12 10:09:53 +00:00
Henrik Lundin
83b5c053b9 Modify NetEqQualityTest
- Take input sample rate as parameter - provides resampling when needed.
- Add support for wav output.

BUG=2692
R=minyue@webrtc.org

Review URL: https://webrtc-codereview.appspot.com/49699004

Cr-Commit-Position: refs/heads/master@{#9158}
2015-05-08 08:34:00 +00:00
minyue@webrtc.org
194fea7640 The lastest commit on this file was in
https://webrtc-codereview.appspot.com/15529004/

The final patch set should have included this, but was missed.

R=turaj@webrtc.org

Review URL: https://webrtc-codereview.appspot.com/18839004

git-svn-id: http://webrtc.googlecode.com/svn/trunk@6755 4adac7df-926f-26a2-2b94-8c16560cd09d
2014-07-22 09:55:51 +00:00
minyue@webrtc.org
6568e97d10 This is to compare NetEq with various codecs under a shared packet loss pattern.
TEST=passed_all_trybots
R=henrik.lundin@webrtc.org, tina.legrand@webrtc.org

Review URL: https://webrtc-codereview.appspot.com/15529004

git-svn-id: http://webrtc.googlecode.com/svn/trunk@6536 4adac7df-926f-26a2-2b94-8c16560cd09d
2014-06-25 12:17:41 +00:00
henrik.lundin@webrtc.org
9c55f0f957 Rename neteq4 folder to neteq
Keep the old neteq4/audio_decoder_unittests.isolate while waiting for
a hard-coded reference to change.

This CL effectively reverts r6257 "Rename neteq4 folder to neteq".

BUG=2996
TBR=tina.legrand@webrtc.org

Review URL: https://webrtc-codereview.appspot.com/21629004

git-svn-id: http://webrtc.googlecode.com/svn/trunk@6367 4adac7df-926f-26a2-2b94-8c16560cd09d
2014-06-09 08:10:28 +00:00
henrik.lundin@webrtc.org
1b9df05c85 Revert 6257 "Rename neteq4 folder to neteq"
> Rename neteq4 folder to neteq
> 
> BUG=2996
> R=turaj@webrtc.org
> 
> Review URL: https://webrtc-codereview.appspot.com/12569005

TBR=henrik.lundin@webrtc.org

Review URL: https://webrtc-codereview.appspot.com/13549004

git-svn-id: http://webrtc.googlecode.com/svn/trunk@6259 4adac7df-926f-26a2-2b94-8c16560cd09d
2014-05-28 07:33:39 +00:00
henrik.lundin@webrtc.org
a90f6d67f7 Rename neteq4 folder to neteq
BUG=2996
R=turaj@webrtc.org

Review URL: https://webrtc-codereview.appspot.com/12569005

git-svn-id: http://webrtc.googlecode.com/svn/trunk@6257 4adac7df-926f-26a2-2b94-8c16560cd09d
2014-05-28 06:23:34 +00:00
Renamed from webrtc/modules/audio_coding/neteq4/tools/neteq_quality_test.cc (Browse further)