4673 Commits

Author SHA1 Message Date
aleloi
1655e45d85 Elimiteted race condition in the AudioMixer.
The mixer allocates an audio frame for each added data source. This
audio frame was deallocated when a source was removed from the
mixer. Source removal could happen during the mixing, and the existing
locking scheme (and the Clang thread checker) was not sufficient to
prevent a data race.

After this change, the mixer doesn't release its lock until it is
finished with the sources' Audio frames. Since multi-threaded access to
the mixer only happens when a source is added or removed, we believe
that this change wouldn't have any noticeable performance impact.

NOTRY=True

BUG=webrtc:6346

Review-Url: https://codereview.webrtc.org/2439283002
Cr-Commit-Position: refs/heads/master@{#14744}
2016-10-24 13:57:03 +00:00
terelius
2206c959f1 Revert of Fix some chromium style warnings in remote_bitrate_estimator.h (patchset #1 id:1 of https://codereview.webrtc.org/2387113008/ )
Reason for revert:
Broke internal project.

Original issue's description:
> Fix some chromium style warnings in remote_bitrate_estimator.h
>
> BUG=webrtc:163
>
> Committed: https://crrev.com/c22bcf4f4bed1f05b5e59127f93b58129cd2627f
> Cr-Commit-Position: refs/heads/master@{#14737}

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

Review-Url: https://codereview.webrtc.org/2444923002
Cr-Commit-Position: refs/heads/master@{#14743}
2016-10-24 13:43:32 +00:00
kwiberg
b60d1962d8 Eliminate left shift of negative value by using multiplication instead
BUG=chromium:655917

Review-Url: https://codereview.webrtc.org/2430393003
Cr-Commit-Position: refs/heads/master@{#14741}
2016-10-24 11:18:50 +00:00
terelius
5de3a7e556 Remove unused variable from delay based BWE.
BUG=None

Review-Url: https://codereview.webrtc.org/2432923003
Cr-Commit-Position: refs/heads/master@{#14739}
2016-10-24 10:43:27 +00:00
terelius
509eadd554 Fix chromium-style warnings.
Separate the null implementation from rtp_rtcp_defines.h, and follow chromium style guide for virtual functions.

BUG=webrtc:163

Review-Url: https://codereview.webrtc.org/2400993002
Cr-Commit-Position: refs/heads/master@{#14738}
2016-10-24 10:24:22 +00:00
terelius
c22bcf4f4b Fix some chromium style warnings in remote_bitrate_estimator.h
BUG=webrtc:163

Review-Url: https://codereview.webrtc.org/2387113008
Cr-Commit-Position: refs/heads/master@{#14737}
2016-10-24 09:57:11 +00:00
nisse
61c053e329 Reland of Delete webrtc::VideoFrame::CopyFrame. (patchset #1 id:1 of https://codereview.webrtc.org/2397943003/ )
Reason for revert:
Dependencies updated.

Original issue's description:
> Revert of Delete webrtc::VideoFrame::CopyFrame. (patchset #2 id:20001 of https://codereview.webrtc.org/2371363003/ )
>
> Reason for revert:
> This CL breaks internal dependencies.
>
> Original issue's description:
> > Delete webrtc::VideoFrame::CopyFrame.
> >
> > BUG=webrtc:5682
> >
> > Committed: https://crrev.com/0e7c7ce35d9449c5bb13328d1bfb04ad32e48ccc
> > Cr-Commit-Position: refs/heads/master@{#14550}
>
> TBR=magjed@webrtc.org,tommi@webrtc.org,nisse@webrtc.org
> # Skipping CQ checks because original CL landed less than 1 days ago.
> NOPRESUBMIT=true
> NOTREECHECKS=true
> NOTRY=true
> BUG=webrtc:5682
>
> Committed: https://crrev.com/21a18ee267146c86e188d95edf6432f71dd53aeb
> Cr-Commit-Position: refs/heads/master@{#14553}

TBR=magjed@webrtc.org,tommi@webrtc.org,ivoc@webrtc.org
# Not skipping CQ checks because original CL landed more than 1 days ago.
BUG=webrtc:5682

Review-Url: https://codereview.webrtc.org/2435963002
Cr-Commit-Position: refs/heads/master@{#14731}
2016-10-24 07:44:17 +00:00
nisse
151572ba05 Delete unused class AudioSourceWithMixStatus.
BUG=webrtc:6346

Review-Url: https://codereview.webrtc.org/2437863003
Cr-Commit-Position: refs/heads/master@{#14728}
2016-10-24 07:11:59 +00:00
peah
764e364933 Several subcomponents inside APM copy render audio from
the render side to the capture side using the same
pattern. Currently this is done independently for the
submodules.

This CL moves the the AEC functionality for this into
APM.

BUG=webrtc:5298, webrtc:6540

Review-Url: https://codereview.webrtc.org/2427553003
Cr-Commit-Position: refs/heads/master@{#14726}
2016-10-22 12:04:35 +00:00
peah
897497361e Added the missing ReadQueuedRenderData() call to the AECM bitexactness test
BUG=webrtc:6573

Review-Url: https://codereview.webrtc.org/2437033002
Cr-Commit-Position: refs/heads/master@{#14725}
2016-10-22 11:00:44 +00:00
peah
12986c4534 Added the missing ReadQueuedRenderData() call to the gain controller bitexactness test
BUG=webrtc:6571

Review-Url: https://codereview.webrtc.org/2441603003
Cr-Commit-Position: refs/heads/master@{#14724}
2016-10-22 09:38:37 +00:00
peah
da38293e51 Added the missing ReadQueuedRenderData() call to the AEC bitexactness test
BUG=webrtc:6572

Review-Url: https://codereview.webrtc.org/2438733002
Cr-Commit-Position: refs/heads/master@{#14723}
2016-10-22 08:08:45 +00:00
henrika
3355f6d6f5 Avoids invalid copy of audio buffer to task queue.
Now does level estimate on the audio threads to avoid complex
copying of audio data to task queue. The old implementation could
also crash due to unclear ownership of the audio buffer.

BUG=webrtc:6569
R=kwiberg@webrtc.org

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

Cr-Commit-Position: refs/heads/master@{#14720}
2016-10-21 10:45:31 +00:00
nisse
c4d2dc4e02 Delete DataLog abstraction, which was almost unused.
Configuration with rtc_enable_data_logging = true was broken in cl
https://codereview.webrtc.org/2054373002/ (which deleted the
FileWrapper::WriteText method), and apparently noone noticed.

BUG=None

Review-Url: https://codereview.webrtc.org/2439473002
Cr-Commit-Position: refs/heads/master@{#14719}
2016-10-21 08:53:01 +00:00
zijiehe
84fbf9ee38 SUCCEEDED macro is misused
SUCCEEDED macro is designed for HRESULT instead of BOOL.
This change exposes my lack of knowledge of native Windows APIs. :(

BUG=https://bugs.chromium.org/p/chromium/issues/detail?id=647067

Review-Url: https://codereview.webrtc.org/2440563003
Cr-Commit-Position: refs/heads/master@{#14716}
2016-10-21 00:00:40 +00:00
zijiehe
bdb8df895a BringSelectedWindowToFront should bring the window to front instead of only focusing it
The API is misused, please refer to the bug for detail explanation.

BUG=https://bugs.chromium.org/p/webrtc/issues/detail?id=6565

Review-Url: https://codereview.webrtc.org/2426423005
Cr-Commit-Position: refs/heads/master@{#14715}
2016-10-20 23:44:22 +00:00
aleloi
6c278491ad Move audio frame memory handling inside AudioMixer.
Simplify the AudioMixer::Source interface and update the mixer
implementation to the new interface.

Instead of asking a mixer source to provide a pointer to an AudioFrame
during each mixing iteration, a mixer should supply a pointer to its
own AudioFrame.

This simplifies lifetime issues as sources do not give away an
internal pointer.

Implementation: when an audio source is added, the mixer allocates a
new AudioFrame. The audio frame is kept together in the internal class
SourceStatus together with the audio source pointer until the source
is removed.

NOTRY=True
BUG=webrtc:6346

Review-Url: https://codereview.webrtc.org/2420913002
Cr-Commit-Position: refs/heads/master@{#14713}
2016-10-20 21:24:46 +00:00
aleloi
920d30bc74 Replaced thread checker with race checker in AudioMixer.
This change is due to an incorrect understanding of the threading
model in Chrome. The new AudioMixer has a thread checker to ensure
that mixing is always done from a single thread. Mixing is done on the
Audio Output Thread. When run in Chrome, it can change. Even if the thread
changes, there is never more than one audio thread, and mixing is done
sequentially.

The threading checks and variable access checks are replaced with
rtc::RaceChecker counterparts.

NOTRY=True
BUG=webrtc:6346

Review-Url: https://codereview.webrtc.org/2437913003
Cr-Commit-Position: refs/heads/master@{#14712}
2016-10-20 21:23:30 +00:00
Sergey Ulanov
58000a0c3d Move shared_desktop_frame.cc to webrtc/modules/desktop_capture:primitives
Previously shared_desktop_frame.cc wasn't in primitives target, but it
is used in remoting client on android and the client should depend only
on primitives, but not desktop_capture overall.

BUG=653612
R=nicholss@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#14709}
2016-10-20 16:34:04 +00:00
danilchap
142f019d87 Append second nack list in same compound rtcp packet
instead of replace

BUG=webrtc:6483

Review-Url: https://codereview.webrtc.org/2426543002
Cr-Commit-Position: refs/heads/master@{#14708}
2016-10-20 15:22:45 +00:00
aleloi
201dfe90a7 Split audio mixer into interface and implementation.
The AudioMixer is now split in a mixer and audio source interface part, which has moved to webrtc/api, and a default implementation part, which lies in webrtc/modules.

This change makes it possible to create other mixer implementations and is a first step to facilitate passing down a mixer from outside of WebRTC.

It will also create less build dependencies when the new mixer has replaced the old one.

NOTRY=True
TBR=henrik.lundin@webrtc.org
BUG=webrtc:6346

Review-Url: https://codereview.webrtc.org/2411313003
Cr-Commit-Position: refs/heads/master@{#14705}
2016-10-20 12:06:44 +00:00
magjed
5a8724564c iOS: Optimize video scaling and cropping
This CL makes scaling and cropping lazy in AVFoundationVideoCapturer and
provides optimized paths for SW and HW encoding. For SW encoding, an
efficient NV12 -> I420 cropping and scaling is implemented in
CoreVideoFrameBuffer::NativeToI420. For HW encoding, an efficient NV12 ->
NV12 cropping and scaling is implemented in
CoreVideoFrameBuffer::CropAndScaleTo. The performance improvement over
the existing cropping and scaling is that it is now done in one step
instead of making an intermediary copy of the Y plane.

There might still be room for improvement in the HW path using some HW
support. That will be explored in a future CL.

BUG=b/30939444

Review-Url: https://codereview.webrtc.org/2394483005
Cr-Commit-Position: refs/heads/master@{#14701}
2016-10-20 10:34:32 +00:00
kthelgason
55928fef1e QualityScaler reset bugfix
BUG=webrtc:6563
TBR=sprang@webrtc.org

Review-Url: https://codereview.webrtc.org/2434803002
Cr-Commit-Position: refs/heads/master@{#14688}
2016-10-20 07:42:59 +00:00
perkj
0489e498eb Change RefCountedObject to use perfect forwarding.
The main reason for doing this is to allow refcounted objects to accept rvalue references in ctor and be able to std::move ctor rvalue arguments.
Also, refcounted.h is now generated using pump.py instead of manually creating each ctor version.

BUG= none

Review-Url: https://codereview.webrtc.org/2425683003
Cr-Commit-Position: refs/heads/master@{#14687}
2016-10-20 07:24:06 +00:00
zijiehe
79f0bf3ab5 A variable in ScreenCapturerWinDirectx has a bad name
BUG=https://bugs.chromium.org/p/chromium/issues/detail?id=314516

Review-Url: https://codereview.webrtc.org/2440613002
Cr-Commit-Position: refs/heads/master@{#14686}
2016-10-20 06:40:44 +00:00
kthelgason
f04f14e772 Revert of Move bitstream parser to more appropriate directory. (patchset #4 id:60001 of https://codereview.webrtc.org/2370853005/ )
Reason for revert:
Breaks internal project

Original issue's description:
> Move current bitstream parser to more appropriate directory.
>
> This CL groups together the code that has to do with parsing H264 bitstreams.
> This code logically belongs together, and having it in the same directory not
> only simplifies things from a project structure perspective, but also makes it
> easier to refactor out common parts incrementally.
> An added benefit is that this simplifies modular compilation, where for example
> one would like a build of WebRTC without the H264 codec-specific parts.
>
> BUG=webrtc:6338
>
> Committed: https://crrev.com/cc6817e9ce4a5ffc73efb660cf0368afbc7d9a4f
> Cr-Commit-Position: refs/heads/master@{#14684}

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

Review-Url: https://codereview.webrtc.org/2430353004
Cr-Commit-Position: refs/heads/master@{#14685}
2016-10-19 17:34:39 +00:00
kthelgason
cc6817e9ce Move current bitstream parser to more appropriate directory.
This CL groups together the code that has to do with parsing H264 bitstreams.
This code logically belongs together, and having it in the same directory not
only simplifies things from a project structure perspective, but also makes it
easier to refactor out common parts incrementally.
An added benefit is that this simplifies modular compilation, where for example
one would like a build of WebRTC without the H264 codec-specific parts.

BUG=webrtc:6338

Review-Url: https://codereview.webrtc.org/2370853005
Cr-Commit-Position: refs/heads/master@{#14684}
2016-10-19 16:31:15 +00:00
danilchap
b6f1fb5337 Delete RTPSender::BuildRtpHeader function
and all dependencies

BUG=webrtc:5565

Review-Url: https://codereview.webrtc.org/2399463009
Cr-Commit-Position: refs/heads/master@{#14682}
2016-10-19 13:11:44 +00:00
brandtr
4e52386339 Reland of Add path for recovered packets from internal::Call to RtpStreamReceiver. (patchset #1 id:1 of https://codereview.webrtc.org/2427733002/ )
Reason for revert:
Flaky test has been fixed.

Original issue's description:
> Revert of Add path for recovered packets from internal::Call to RtpStreamReceiver. (patchset #2 id:60001 of https://codereview.webrtc.org/2390823009/ )
>
> Reason for revert:
> Speculative revert as it may be the cause of the DrMemory test failure:
> https://build.chromium.org/p/client.webrtc/builders/Win%20DrMemory%20Full/builds/5115
>
> Original issue's description:
> > Add path for recovered packets from internal::Call to RtpStreamReceiver.
> >
> > When the FlexfecReceiver recovers media packets, it inserts these into
> > internal::Call, which then distributes them to the appropriate
> > VideoReceiveStream/RtpStreamReceiver.
> >
> > BUG=webrtc:5654
> >
> > Committed: https://crrev.com/9c4b4b47f4325b48e1856566a30983f9e4e30dd0
> > Cr-Commit-Position: refs/heads/master@{#14642}
>
> TBR=stefan@webrtc.org,brandtr@webrtc.org
> # Skipping CQ checks because original CL landed less than 1 days ago.
> NOPRESUBMIT=true
> NOTREECHECKS=true
> NOTRY=true
> BUG=webrtc:5654
>
> Committed: https://crrev.com/862d74d0176fa762b3c96cf20bd36f27e7001a47
> Cr-Commit-Position: refs/heads/master@{#14652}

TBR=stefan@webrtc.org,honghaiz@webrtc.org
# Not skipping CQ checks because original CL landed more than 1 days ago.
BUG=webrtc:5654

Review-Url: https://codereview.webrtc.org/2428303004
Cr-Commit-Position: refs/heads/master@{#14677}
2016-10-19 06:50:53 +00:00
zijiehe
249beee124 Remove DesktopRegion parameter from DesktopCapturer::Capture
BUG=https://bugs.chromium.org/p/webrtc/issues/detail?id=6513

Review-Url: https://codereview.webrtc.org/2433503002
Cr-Commit-Position: refs/heads/master@{#14676}
2016-10-19 06:13:38 +00:00
zijiehe
6a4607e100 Deflaky ScreenCapturerTest
ScreenCapturer tests may fail on trybot, so this change is to fix the issue.

Changes include,
1. Sometimes, a capturer may capture part of the change, i.e. usually the draw
actions are not atomic. So the updated_region may be inaccurate. So I have added
a MayDrawIncompleteShapes() function in ScreenDrawer. If it returns false, the
updated_region check will be ignored.
2. Several test cases may run concurrently, which makes one ScreenDrawer won't
really work. Its window may be covered by another ScreenDrawer. So I have added
a system wide lock to ensure only one ScreenDrawer is working at a certain time.
3. On unity (Linux), the top several pixels of a window may be covered by a
shadow effect if the window is not focused. So I have added a BringToFront()
function, and call it in WaitForPendingDraws().
4. On Windows, the drawn shapes are 'temporary drawing', which will be erased
once the window is covered by another one. So I repeat DrawRectangle() function
call in the test case.

TODO(zijiehe): The DISABLED_ prefixes will be added back after the code review.
And I will move these test cases into modules_test in a coming change.

BUG=647067

Review-Url: https://codereview.webrtc.org/2337073007
Cr-Commit-Position: refs/heads/master@{#14674}
2016-10-19 01:22:25 +00:00
Irfan Sheriff
1eb12934e7 Handle BW drop in ALR region and initiate probing
Original change by isheriff@chromium.org: http://crrev.com/2387463002#ps40001

BUG=webrtc:6332
TBR=philipel@webrtc.org, stefan@webrtc.org

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

Patch from Irfan Sheriff <isheriff@chromium.org>.

Cr-Commit-Position: refs/heads/master@{#14673}
2016-10-19 00:04:35 +00:00
terelius
6ed592d0ab Rename variables to reflect that DelayBasedBwe lives on the send side rather than receive side.
BUG=0

Review-Url: https://codereview.webrtc.org/2404253004
Cr-Commit-Position: refs/heads/master@{#14662}
2016-10-18 12:55:36 +00:00
henrika
5588a13fe7 Now uses rtc::Buffer in AudioDeviceBuffer.
The main goal of this CL is to remove old buffer handling using static arrays
and switch to the improved rtc::Buffer class instead.

By doing so, we can remove some members (since Buffer maintains them instead) and
do some additional cleanup.

This CL also fixes some minor style issues and improves the locking mechanism.

Finally, AudioDeviceBuffer::SetRecordingChannel() is deprecated since it has never been
used and is not included in any test.

BUG=NONE

Review-Url: https://codereview.webrtc.org/2333273002
Cr-Commit-Position: refs/heads/master@{#14661}
2016-10-18 12:14:35 +00:00
ossu
7a3776102f Removed RTPHeader from NetEq's Packet struct.
Only three items in the (rather large) header were actually used after
InsertPacket: payloadType, timestamp and sequenceNumber. They are now
put directly into Packet. This saves 129 bytes per Packet that no
longer need to be allocated and deallocated.

This also works towards decoupling NetEq from RTP. As part of that,
I've moved the NACK code earlier in InsertPacketInternal, together
with other things that directly reference the RTPHeader.

BUG=webrtc:6549

Review-Url: https://codereview.webrtc.org/2411183003
Cr-Commit-Position: refs/heads/master@{#14658}
2016-10-18 11:06:19 +00:00
honghaiz
862d74d017 Revert of Add path for recovered packets from internal::Call to RtpStreamReceiver. (patchset #2 id:60001 of https://codereview.webrtc.org/2390823009/ )
Reason for revert:
Speculative revert as it may be the cause of the DrMemory test failure:
https://build.chromium.org/p/client.webrtc/builders/Win%20DrMemory%20Full/builds/5115

Original issue's description:
> Add path for recovered packets from internal::Call to RtpStreamReceiver.
>
> When the FlexfecReceiver recovers media packets, it inserts these into
> internal::Call, which then distributes them to the appropriate
> VideoReceiveStream/RtpStreamReceiver.
>
> BUG=webrtc:5654
>
> Committed: https://crrev.com/9c4b4b47f4325b48e1856566a30983f9e4e30dd0
> Cr-Commit-Position: refs/heads/master@{#14642}

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

Review-Url: https://codereview.webrtc.org/2427733002
Cr-Commit-Position: refs/heads/master@{#14652}
2016-10-17 16:42:38 +00:00
danilchap
2f255d8d67 Replace const -> constexpr for rtcp Packet Type
for consistency with other rtcp packet classes.

BUG=webrtc:5260

Review-Url: https://codereview.webrtc.org/2361853002
Cr-Commit-Position: refs/heads/master@{#14648}
2016-10-17 09:07:59 +00:00
danilchap
c1f40b7bae Remove RtcpPacket dependency on rtcp_utility
and thus IP_PACKET_SIZE constant:
Build() use BlockLength() instead of constant IP_PACKET_SIZE for packet
capacity, adding extra checks about packet generation in tests.
Build(callback) removed as unused.
definitions reordered to follow style.

BUG=webrtc:5260

Review-Url: https://codereview.webrtc.org/2270753002
Cr-Commit-Position: refs/heads/master@{#14647}
2016-10-17 08:44:49 +00:00
peah
883ad662f4 Removed the deprecated audioproc executable
BUG=webrtc:6536

Review-Url: https://codereview.webrtc.org/2425583002
Cr-Commit-Position: refs/heads/master@{#14645}
2016-10-17 07:08:56 +00:00
kjellander
e40a7ee007 GN: Exclude suppressions of Chromium Clang warnings for Chromium builds.
These suppressions are causing GN errors when Chromium targets are depending
directly on WebRTC targets (needed for https://codereview.chromium.org/2413103004)

BUG=webrtc:4256
NOTRY=True

Review-Url: https://codereview.webrtc.org/2408133008
Cr-Commit-Position: refs/heads/master@{#14644}
2016-10-17 06:56:20 +00:00
brandtr
9c4b4b47f4 Add path for recovered packets from internal::Call to RtpStreamReceiver.
When the FlexfecReceiver recovers media packets, it inserts these into
internal::Call, which then distributes them to the appropriate
VideoReceiveStream/RtpStreamReceiver.

BUG=webrtc:5654

Review-Url: https://codereview.webrtc.org/2390823009
Cr-Commit-Position: refs/heads/master@{#14642}
2016-10-16 21:11:00 +00:00
peah
8f7cc7e77d This CL corrects the emptying of the render queues for the
AEC and AECM when these become full to also work when not
in debug mode.

BUG=webrtc:6530

Review-Url: https://codereview.webrtc.org/2419023002
Cr-Commit-Position: refs/heads/master@{#14637}
2016-10-14 10:23:39 +00:00
zijiehe
91902cb6c0 Remove DesktopRegion parameter from DesktopCapturer::Capture.
To ensure this change won't break Chromium, this is the first change, to add a
new CaptureFrame() function, and let Capture(DesktopRegion) and CaptureFrame()
call each other. So both a legacy consumer or a legacy implementation won't be
broken.

BUG=https://bugs.chromium.org/p/webrtc/issues/detail?id=6513

Review-Url: https://codereview.webrtc.org/2409833002
Cr-Commit-Position: refs/heads/master@{#14635}
2016-10-13 23:47:54 +00:00
sprang
982bf89444 Revert of Add RtcpRttStats to AudioStream (patchset #1 id:1 of https://codereview.webrtc.org/2402333002/ )
Reason for revert:
Speculative revert.
Intermittent memory access errors suspected to be caused by this cl.

See for instance https://build.chromium.org/p/client.webrtc/builders/Win%20DrMemory%20Light/builds/8018

UNADDRESSABLE ACCESS of freed memory: reading 0x0331d330-0x0331d334 4 byte(s)
# 0 webrtc::voe::RtcpRttStatsProxy::LastProcessedRtt
# 1 webrtc::ModuleRtpRtcpImpl::Process

Original issue's description:
> Add RtcpRttStats to AudioStream
>
> BUG=webrtc:6508
>
> Committed: https://crrev.com/e0729c56d35acfaf9738fdb32c6508cd78eaf089
> Cr-Commit-Position: refs/heads/master@{#14595}

TBR=stefan@webrtc.org,minyue@webrtc.org,solenberg@webrtc.org,michaelt@webrtc.org
# Not skipping CQ checks because original CL landed more than 1 days ago.
BUG=webrtc:6508

Review-Url: https://codereview.webrtc.org/2415943002
Cr-Commit-Position: refs/heads/master@{#14631}
2016-10-13 13:23:18 +00:00
henrik.lundin
0d8385770b NetEq: Convert AverageIAT from int to float calculations
With this change, the calculations inside AverageIAT are changed to be
in double-precision floating point instead of in fixed point. Also,
the method's name is changed to EstimatedClockDriftPpm to better
reflect what it returns.

A few unit tests had to be updated because of minor numerical
differences.

Also removing the UBSan suppression related to this issue.

BUG=webrtc:5889

Review-Url: https://codereview.webrtc.org/2408653002
Cr-Commit-Position: refs/heads/master@{#14628}
2016-10-13 10:35:58 +00:00
henrik.lundin
c9ec8758db NetEq: Remove special case for Merge without Expand
This was an ill tested special case which turned out to be more problem
than benefit. The special case was only triggered when the decoder frame
size was smaller than 10 ms, which is more or less unsupported by NetEq.

Also fixed a bug in a test, a bug which was exposed by the code change.

BUG=chromium:654983

Review-Url: https://codereview.webrtc.org/2412883002
Cr-Commit-Position: refs/heads/master@{#14627}
2016-10-13 09:43:38 +00:00
henrika
722b0dc108 Revert of Android audio playout now supports non-call media streams (patchset #3 id:10004 of https://codereview.webrtc.org/2411263003/ )
Reason for revert:
There is a risk of ending up in a bad state due to race conditions with this patch. Tests in downstream clients have shown that it can
happen that an output stream is opened up in MUSIC mode when it should not.

Reverting since the new functionality added here is not worth the
risk of breaking existing clients.

Original issue's description:
> Android audio playout now supports non-call media streams.
>
> The default (preferred) stream type for output audio is STREAM_VOICE_CALL since the WebRTC stack is mainly intended for VoIP calls. But if the user wants to run in another mode than COMM mode, we now accept it and change the stream type to STREAM_MUSIC instead. It can e.g. be suitable for applications that does not record audio or if a call shall be casted to a Chromecast device.
>
> The solution is somewhat experimental.
>
> NOTRY=TRUE
>
> BUG=webrtc:4767
>
> Committed: https://crrev.com/872f614111f436d15e29516ce19c3b63d25b8639
> Cr-Commit-Position: refs/heads/master@{#14613}

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

Review-Url: https://codereview.webrtc.org/2420583002
Cr-Commit-Position: refs/heads/master@{#14626}
2016-10-13 08:12:37 +00:00
Stefan Holmer
db158f9b9e Fix experiment name in BitrateControllerTest.
TBR=mflodman@webrtc.org
BUG=webrtc:6519

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

Cr-Commit-Position: refs/heads/master@{#14620}
2016-10-13 00:12:03 +00:00
stefan
77c663d0f5 Give FeedbackTimeout experiment the correct name.
NOTRY=true
BUG=webrtc:6519

Review-Url: https://codereview.webrtc.org/2410323002
Cr-Commit-Position: refs/heads/master@{#14619}
2016-10-12 22:57:49 +00:00
stefan
12a39f4100 Don't crash on unexpected stap-a or fu-a.
BUG=chromium:655091

Review-Url: https://codereview.webrtc.org/2406363004
Cr-Commit-Position: refs/heads/master@{#14618}
2016-10-12 22:30:18 +00:00