Commit Graph

5603 Commits

Author SHA1 Message Date
b5f5bdba77 Add unit tests for qp parser.
Add test for vp8/vp9 qp parser in both videoprocessor_integrationtest.
Check the qp from parser equal to that from the encoder
on every frame in every test.

Add test for vp8/vp9 qp parser in vp8/vp9_impl_test.
Check the qp parser on a single key frame.

BUG=None

Review-Url: https://codereview.webrtc.org/2903163002
Cr-Commit-Position: refs/heads/master@{#18334}
2017-05-30 17:57:25 +00:00
6c4bbfa06f Update max TL0 frame interval for screensharing.
The previous limit leaved no margin for RTT.

BUG=webrtc:4172

Review-Url: https://codereview.webrtc.org/2911243002
Cr-Commit-Position: refs/heads/master@{#18333}
2017-05-30 17:08:23 +00:00
12de077b14 Avoiding check on reordering configs in ANA if there is no controller has scoring point.
BUG=webrtc:7729

Review-Url: https://codereview.webrtc.org/2910193002
Cr-Commit-Position: refs/heads/master@{#18331}
2017-05-30 15:56:08 +00:00
678d2ee651 Cosmetic change in ANA: renaming characteristic points for consistency.
BUG=none

Review-Url: https://codereview.webrtc.org/2907153004
Cr-Commit-Position: refs/heads/master@{#18329}
2017-05-30 14:36:20 +00:00
77cd58e140 This cl removes RtcEventLog deps to call:call_interfaces. The purpose is to be able to use the event log from the upcoming RtpTransport.
Biggest change is to Remove MediaType as argument to RtcEventLog::LogRtpHeader and RtcEventLog::LogRtcpHeader.
Since the type is used by tools, these tools are rewritten to figure out the media type from the configurations instead.

BUG=webrtc:7538
TBR=solenberg@webrtc.org // For call.cc and voiceengine.cc

Review-Url: https://codereview.webrtc.org/2855143002
Cr-Commit-Position: refs/heads/master@{#18324}
2017-05-30 10:52:10 +00:00
48d21a23c6 Persist RTP state for FlexFEC.
Before this CL, the RTP state would be re-randomized after a
recreation of VideoSendStream. That might lead to us sending
a non-compliant RTP stream, which is avoided after the
changes in this CL.

BUG=webrtc:5654
TBR=pbos@webrtc.org  # Trivial change to fuzzer.

Review-Url: https://codereview.webrtc.org/2912713002
Cr-Commit-Position: refs/heads/master@{#18322}
2017-05-30 09:32:12 +00:00
bb6f7524ba Improved audio buffer handling for iOS.
This change:

Reduces complexity for audio playout by removing a redundant memcopy in the output audio path.

Adds support for iOS simulator for playout since we now allow the audio layer to ask for different sizes
of audio buffers at each callback. Real iOS devices always asks for the same size, simulators does not.
This change comes without any new cost for real devices.

BUG=b/37580746

Review-Url: https://codereview.webrtc.org/2894873002
Cr-Commit-Position: refs/heads/master@{#18321}
2017-05-30 09:01:30 +00:00
2f08879fb1 Reland of Split iOS sdk in to separate targets (patchset #1 id:1 of https://codereview.webrtc.org/2911053002/ )
Reason for revert:
Take three of relanding this after all internal issues have been resolved.

Original issue's description:
> Revert of Split iOS sdk in to separate targets (patchset #3 id:320001 of https://codereview.webrtc.org/2893843003/ )
>
> Reason for revert:
> Breaks downstream project.
>
> Original issue's description:
> > Reland of Split iOS sdk in to separate targets (patchset #1 id:1 of https://codereview.webrtc.org/2893593002/ )
> >
> > Reason for revert:
> > Take two of fixing downstream issues?
> >
> > Original issue's description:
> > > Revert of Split iOS sdk in to separate targets (patchset #1 id:1 of https://codereview.webrtc.org/2890733003/ )
> > >
> > > Reason for revert:
> > > Still problems with downstream projects
> > >
> > > Original issue's description:
> > > > Reland of Split iOS sdk in to separate targets (patchset #1 id:1 of https://codereview.webrtc.org/2890513002/ )
> > > >
> > > > Reason for revert:
> > > > Fixing downstream breakages
> > > >
> > > > Original issue's description:
> > > > > Revert of Split iOS sdk in to separate targets (patchset #13 id:280001 of https://codereview.webrtc.org/2862543002/ )
> > > > >
> > > > > Reason for revert:
> > > > > Breaking downstream projects.
> > > > >
> > > > > Original issue's description:
> > > > > > Split iOS sdk in to separate targets
> > > > > >
> > > > > > This CL splits the iOS sdk into separate static libraries for video,
> > > > > > audio, ui, common, and peerconnection-related code. This will in the
> > > > > > future make it easier to compile WebRTC without unneeded components.
> > > > > >
> > > > > > BUG=webrtc:4867
> > > > > >
> > > > > > Review-Url: https://codereview.webrtc.org/2862543002
> > > > > > Cr-Commit-Position: refs/heads/master@{#18166}
> > > > > > Committed: 52c83fe710
> > > > >
> > > > > TBR=magjed@webrtc.org,denicija@webrtc.org,tkchin@webrtc.org,henrika@webrtc.org,kthelgason@webrtc.org
> > > > > # Skipping CQ checks because original CL landed less than 1 days ago.
> > > > > NOPRESUBMIT=true
> > > > > NOTREECHECKS=true
> > > > > NOTRY=true
> > > > > BUG=webrtc:4867
> > > > >
> > > > > Review-Url: https://codereview.webrtc.org/2890513002
> > > > > Cr-Commit-Position: refs/heads/master@{#18170}
> > > > > Committed: 9756238084
> > > >
> > > > TBR=magjed@webrtc.org,denicija@webrtc.org,tkchin@webrtc.org,henrika@webrtc.org,charujain@webrtc.org
> > > > # Skipping CQ checks because original CL landed less than 1 days ago.
> > > > NOPRESUBMIT=true
> > > > NOTREECHECKS=true
> > > > NOTRY=true
> > > > BUG=webrtc:4867
> > > >
> > > > Review-Url: https://codereview.webrtc.org/2890733003
> > > > Cr-Commit-Position: refs/heads/master@{#18174}
> > > > Committed: d51e042492
> > >
> > > TBR=magjed@webrtc.org,denicija@webrtc.org,tkchin@webrtc.org,henrika@webrtc.org,charujain@webrtc.org
> > > # Skipping CQ checks because original CL landed less than 1 days ago.
> > > NOPRESUBMIT=true
> > > NOTREECHECKS=true
> > > NOTRY=true
> > > BUG=webrtc:4867
> > >
> > > Review-Url: https://codereview.webrtc.org/2893593002
> > > Cr-Commit-Position: refs/heads/master@{#18182}
> > > Committed: 37144b214e
> >
> > TBR=magjed@webrtc.org,denicija@webrtc.org,tkchin@webrtc.org,henrika@webrtc.org,charujain@webrtc.org
> > # Skipping CQ checks because original CL landed less than 1 days ago.
> > NOPRESUBMIT=true
> > NOTREECHECKS=true
> > NOTRY=true
> > BUG=webrtc:4867
> >
> > Review-Url: https://codereview.webrtc.org/2893843003
> > Cr-Commit-Position: refs/heads/master@{#18303}
> > Committed: 580c3522d2
>
> TBR=magjed@webrtc.org,denicija@webrtc.org,tkchin@webrtc.org,henrika@webrtc.org,charujain@webrtc.org,kthelgason@webrtc.org
> # Skipping CQ checks because original CL landed less than 1 days ago.
> NOPRESUBMIT=true
> NOTREECHECKS=true
> NOTRY=true
> BUG=webrtc:4867
>
> Review-Url: https://codereview.webrtc.org/2911053002
> Cr-Commit-Position: refs/heads/master@{#18309}
> Committed: af5c05540c

TBR=magjed@webrtc.org,denicija@webrtc.org,tkchin@webrtc.org,henrika@webrtc.org,charujain@webrtc.org,mbonadei@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=webrtc:4867

Review-Url: https://codereview.webrtc.org/2913753003
Cr-Commit-Position: refs/heads/master@{#18319}
2017-05-30 08:48:47 +00:00
53800ed191 Remove RTPSenderVideo::FecPacketOverhead() since it is unused.
BUG=None

Review-Url: https://codereview.webrtc.org/2914493002
Cr-Commit-Position: refs/heads/master@{#18315}
2017-05-30 06:34:37 +00:00
af5c05540c Revert of Split iOS sdk in to separate targets (patchset #3 id:320001 of https://codereview.webrtc.org/2893843003/ )
Reason for revert:
Breaks downstream project.

Original issue's description:
> Reland of Split iOS sdk in to separate targets (patchset #1 id:1 of https://codereview.webrtc.org/2893593002/ )
>
> Reason for revert:
> Take two of fixing downstream issues?
>
> Original issue's description:
> > Revert of Split iOS sdk in to separate targets (patchset #1 id:1 of https://codereview.webrtc.org/2890733003/ )
> >
> > Reason for revert:
> > Still problems with downstream projects
> >
> > Original issue's description:
> > > Reland of Split iOS sdk in to separate targets (patchset #1 id:1 of https://codereview.webrtc.org/2890513002/ )
> > >
> > > Reason for revert:
> > > Fixing downstream breakages
> > >
> > > Original issue's description:
> > > > Revert of Split iOS sdk in to separate targets (patchset #13 id:280001 of https://codereview.webrtc.org/2862543002/ )
> > > >
> > > > Reason for revert:
> > > > Breaking downstream projects.
> > > >
> > > > Original issue's description:
> > > > > Split iOS sdk in to separate targets
> > > > >
> > > > > This CL splits the iOS sdk into separate static libraries for video,
> > > > > audio, ui, common, and peerconnection-related code. This will in the
> > > > > future make it easier to compile WebRTC without unneeded components.
> > > > >
> > > > > BUG=webrtc:4867
> > > > >
> > > > > Review-Url: https://codereview.webrtc.org/2862543002
> > > > > Cr-Commit-Position: refs/heads/master@{#18166}
> > > > > Committed: 52c83fe710
> > > >
> > > > TBR=magjed@webrtc.org,denicija@webrtc.org,tkchin@webrtc.org,henrika@webrtc.org,kthelgason@webrtc.org
> > > > # Skipping CQ checks because original CL landed less than 1 days ago.
> > > > NOPRESUBMIT=true
> > > > NOTREECHECKS=true
> > > > NOTRY=true
> > > > BUG=webrtc:4867
> > > >
> > > > Review-Url: https://codereview.webrtc.org/2890513002
> > > > Cr-Commit-Position: refs/heads/master@{#18170}
> > > > Committed: 9756238084
> > >
> > > TBR=magjed@webrtc.org,denicija@webrtc.org,tkchin@webrtc.org,henrika@webrtc.org,charujain@webrtc.org
> > > # Skipping CQ checks because original CL landed less than 1 days ago.
> > > NOPRESUBMIT=true
> > > NOTREECHECKS=true
> > > NOTRY=true
> > > BUG=webrtc:4867
> > >
> > > Review-Url: https://codereview.webrtc.org/2890733003
> > > Cr-Commit-Position: refs/heads/master@{#18174}
> > > Committed: d51e042492
> >
> > TBR=magjed@webrtc.org,denicija@webrtc.org,tkchin@webrtc.org,henrika@webrtc.org,charujain@webrtc.org
> > # Skipping CQ checks because original CL landed less than 1 days ago.
> > NOPRESUBMIT=true
> > NOTREECHECKS=true
> > NOTRY=true
> > BUG=webrtc:4867
> >
> > Review-Url: https://codereview.webrtc.org/2893593002
> > Cr-Commit-Position: refs/heads/master@{#18182}
> > Committed: 37144b214e
>
> TBR=magjed@webrtc.org,denicija@webrtc.org,tkchin@webrtc.org,henrika@webrtc.org,charujain@webrtc.org
> # Skipping CQ checks because original CL landed less than 1 days ago.
> NOPRESUBMIT=true
> NOTREECHECKS=true
> NOTRY=true
> BUG=webrtc:4867
>
> Review-Url: https://codereview.webrtc.org/2893843003
> Cr-Commit-Position: refs/heads/master@{#18303}
> Committed: 580c3522d2

TBR=magjed@webrtc.org,denicija@webrtc.org,tkchin@webrtc.org,henrika@webrtc.org,charujain@webrtc.org,kthelgason@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=webrtc:4867

Review-Url: https://codereview.webrtc.org/2911053002
Cr-Commit-Position: refs/heads/master@{#18309}
2017-05-29 16:57:37 +00:00
30e8931ea7 Delete RtpData::OnRecoveredPacket, use RecoveredPacketReceiver instead.
BUG=webrtc:7135

Review-Url: https://codereview.webrtc.org/2886813002
Cr-Commit-Position: refs/heads/master@{#18305}
2017-05-29 15:16:37 +00:00
580c3522d2 Reland of Split iOS sdk in to separate targets (patchset #1 id:1 of https://codereview.webrtc.org/2893593002/ )
Reason for revert:
Take two of fixing downstream issues?

Original issue's description:
> Revert of Split iOS sdk in to separate targets (patchset #1 id:1 of https://codereview.webrtc.org/2890733003/ )
>
> Reason for revert:
> Still problems with downstream projects
>
> Original issue's description:
> > Reland of Split iOS sdk in to separate targets (patchset #1 id:1 of https://codereview.webrtc.org/2890513002/ )
> >
> > Reason for revert:
> > Fixing downstream breakages
> >
> > Original issue's description:
> > > Revert of Split iOS sdk in to separate targets (patchset #13 id:280001 of https://codereview.webrtc.org/2862543002/ )
> > >
> > > Reason for revert:
> > > Breaking downstream projects.
> > >
> > > Original issue's description:
> > > > Split iOS sdk in to separate targets
> > > >
> > > > This CL splits the iOS sdk into separate static libraries for video,
> > > > audio, ui, common, and peerconnection-related code. This will in the
> > > > future make it easier to compile WebRTC without unneeded components.
> > > >
> > > > BUG=webrtc:4867
> > > >
> > > > Review-Url: https://codereview.webrtc.org/2862543002
> > > > Cr-Commit-Position: refs/heads/master@{#18166}
> > > > Committed: 52c83fe710
> > >
> > > TBR=magjed@webrtc.org,denicija@webrtc.org,tkchin@webrtc.org,henrika@webrtc.org,kthelgason@webrtc.org
> > > # Skipping CQ checks because original CL landed less than 1 days ago.
> > > NOPRESUBMIT=true
> > > NOTREECHECKS=true
> > > NOTRY=true
> > > BUG=webrtc:4867
> > >
> > > Review-Url: https://codereview.webrtc.org/2890513002
> > > Cr-Commit-Position: refs/heads/master@{#18170}
> > > Committed: 9756238084
> >
> > TBR=magjed@webrtc.org,denicija@webrtc.org,tkchin@webrtc.org,henrika@webrtc.org,charujain@webrtc.org
> > # Skipping CQ checks because original CL landed less than 1 days ago.
> > NOPRESUBMIT=true
> > NOTREECHECKS=true
> > NOTRY=true
> > BUG=webrtc:4867
> >
> > Review-Url: https://codereview.webrtc.org/2890733003
> > Cr-Commit-Position: refs/heads/master@{#18174}
> > Committed: d51e042492
>
> TBR=magjed@webrtc.org,denicija@webrtc.org,tkchin@webrtc.org,henrika@webrtc.org,charujain@webrtc.org
> # Skipping CQ checks because original CL landed less than 1 days ago.
> NOPRESUBMIT=true
> NOTREECHECKS=true
> NOTRY=true
> BUG=webrtc:4867
>
> Review-Url: https://codereview.webrtc.org/2893593002
> Cr-Commit-Position: refs/heads/master@{#18182}
> Committed: 37144b214e

TBR=magjed@webrtc.org,denicija@webrtc.org,tkchin@webrtc.org,henrika@webrtc.org,charujain@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=webrtc:4867

Review-Url: https://codereview.webrtc.org/2893843003
Cr-Commit-Position: refs/heads/master@{#18303}
2017-05-29 12:46:00 +00:00
d7fdb8014d Reland of Removes usage of native base::android::GetApplicationContext()
The change is now compatible with the old JVM::Initialize API. The
context is passed to the ContextUtils class when calling its deprecated
signature.

BUG=webrtc:7665
NOTRY=True # Only comment changes since the last patchset.

Review-Url: https://codereview.webrtc.org/2903253004
Cr-Commit-Position: refs/heads/master@{#18268}
2017-05-26 08:51:53 +00:00
13ae11a418 Add observer for AVAudioSession.outputVolume
BUG=webrtc:7696

Review-Url: https://codereview.webrtc.org/2895263006
Cr-Commit-Position: refs/heads/master@{#18267}
2017-05-26 00:52:20 +00:00
edd6eea542 Rename elad.alon to eladalon, to avoid confusion between repositories.
BUG=None
NOTRY=true

Review-Url: https://codereview.webrtc.org/2899303002
Cr-Commit-Position: refs/heads/master@{#18264}
2017-05-25 07:15:35 +00:00
548cdce7bc Revert of https://codereview.webrtc.org/2889183002/
And also revert https://codereview.webrtc.org/2888093005/ (Chromium roll) which has a dependency on 2889183002

BUG=webrtc:7707

Review-Url: https://codereview.webrtc.org/2897423002
Cr-Commit-Position: refs/heads/master@{#18263}
2017-05-24 23:45:57 +00:00
20acdf2443 Add vp9 QP parser.
BUG=webrtc:7662

Review-Url: https://codereview.webrtc.org/2891803003
Cr-Commit-Position: refs/heads/master@{#18260}
2017-05-24 17:00:16 +00:00
ae550e397a Correct sequence-number injection into packets in rtp_packet_unittest.cc
BUG=None

Review-Url: https://codereview.webrtc.org/2899293002
Cr-Commit-Position: refs/heads/master@{#18257}
2017-05-24 15:28:13 +00:00
0afb13014b AudioEncoderPcm16B: Number of bits/sample is 16, not 2
Clearly, this was a case of bit/byte confusion.

BUG=none

Review-Url: https://codereview.webrtc.org/2904883002
Cr-Commit-Position: refs/heads/master@{#18254}
2017-05-24 11:09:52 +00:00
3696f7efc4 Remove unneeded gmock header from RPLR UT
BUG=None

Review-Url: https://codereview.webrtc.org/2898193002
Cr-Commit-Position: refs/heads/master@{#18250}
2017-05-24 07:13:25 +00:00
1b92722ad5 Simplified the ERLE computation code in AEC3
BUG=webrtc:7519

Review-Url: https://codereview.webrtc.org/2901253002
Cr-Commit-Position: refs/heads/master@{#18249}
2017-05-24 06:44:47 +00:00
b34f6a8520 Remove deprecated isFirstPacket member name
Original rename .isFirstPacket to .is_first_packet_in_frame
was done in https://codereview.webrtc.org/2614503002

BUG=None

Review-Url: https://codereview.webrtc.org/2895473004
Cr-Commit-Position: refs/heads/master@{#18247}
2017-05-23 18:06:56 +00:00
95e9754e40 More gracefully handle timing errors, such as unexpected changes in the rtp timestamp.
BUG=webrtc:7682

Review-Url: https://codereview.webrtc.org/2898763005
Cr-Commit-Position: refs/heads/master@{#18245}
2017-05-23 16:52:18 +00:00
7a3006bae7 Fix packetization logic to leave space for extensions in the last packet
Change packetizer interface to explicitly return number of packets
instead of a last flag. Account for extra space needed in the last
packet.

BUG=webrtc:7588,webrtc:7594

Review-Url: https://codereview.webrtc.org/2871173008
Cr-Commit-Position: refs/heads/master@{#18244}
2017-05-23 16:34:21 +00:00
d019667c00 Linux desktopCapture: fix the cursor position issue in Window sharing
On Linux, during Windwo sharing, the cursore capture may happen in the parent
window of the target. And the parent window may have some decorations added by
window manager(Chrome windows don't have those decorations.), so the relative
cursor position to the parent window with decorations may differ to its child
target window. The offset includes the height of caption bar and the around
shadow and border.
This problem only happens with Window sharing on Linux.

The fix is to translate the coordinates from the parent window to the coordinates space of the target window.

BUG=723889

Review-Url: https://codereview.webrtc.org/2889063002
Cr-Commit-Position: refs/heads/master@{#18243}
2017-05-23 16:31:14 +00:00
06013e99ac AecDump implementation.
This CL implements webrtc::AecDump, which is an interface defined in
https://codereview.webrtc.org/2778783002.

This AudioProcessing submodule writes audio and APM state to a
file. The file writing is done by posting IO tasks
(write_to_file_task.h) on an rtc::TaskQueue. There is an existing
implementation for this through AudioProcessing::StartDebugRecording()
and AudioProcessing::StopDebugRecording(). This implementation still
works, and is used as the default until this dependent CL:
https://codereview.webrtc.org/2896813002/.

To be able to build webrtc without protobuf support, the interface is
isolated from protobuf types. Audio data from AudioProcessing is
passed to AecDumpImpl through the AecDump interface. There it is
stored in protobuf objects, which are posted on the task queue.

This functionality is verified correct by the CL
https://codereview.webrtc.org/2864373002, which enables this recording
submodule in APM tests.

BUG=webrtc:7404

Review-Url: https://codereview.webrtc.org/2865113002
Cr-Commit-Position: refs/heads/master@{#18241}
2017-05-23 15:52:05 +00:00
f27c5b8d6e Add FlexfecReceiver unit test for infinite recovery loop.
This CL adds unit tests to the FlexfecReceiver, verifying that the
infinite recovery loop described in
https://codereview.webrtc.org/2867943003/ is tested for.

BUG=webrtc:5654

Review-Url: https://codereview.webrtc.org/2895083002
Cr-Commit-Position: refs/heads/master@{#18240}
2017-05-23 15:38:43 +00:00
7d79e63a48 Cast sequence number in RtpFrameObject.
BUG=webrtc:7700

Review-Url: https://codereview.webrtc.org/2902743002
Cr-Commit-Position: refs/heads/master@{#18237}
2017-05-23 15:19:11 +00:00
916170ae46 Don't boost QP after drop unless there is sufficient bandwidth
If a frame is dropped and re-encoded because it exceeded the target
bitrate by a large factor, the next frame will be encoded at max qp
(worst quality) in order to get a frame through in a timely manner. The
next frame after this will still have lower quality since the rate
controller essentially gets reset. In order to mitigate that we boost
the qp for that next frame, which brings the stream back to a good
quality quicker.

However, if the network conditions are _really_ bad, this boosted qp
may be too large, causing the frame again to be dropped an re-encoded.

This CL set's a minimum bitrate available in order to enabling the
boosting in the first place.
It also adjusts a timeout (max time between frames in TL0), since a
too small value and very difficult frames in conjunction with the
mentioned bad network could actually cause bad network over-utilization
in turn leading to packet loss and bad follow-on effects to that.

There was also some slop in the rate keeping for the two layers.
This has been tightened up and affected test cases have been fixed.

BUG=webrtc:7694

Review-Url: https://codereview.webrtc.org/2897983002
Cr-Commit-Position: refs/heads/master@{#18236}
2017-05-23 14:47:55 +00:00
7855fff5bf Reland of moves usage of native base::android::GetApplicationContext() (patchset #1 id:1 of https://codereview.webrtc.org/2894593002/ )
Reason for revert:
Fix issue.

Original issue's description:
> Revert of Removes usage of native base::android::GetApplicationContext() (patchset #6 id:120001 of https://codereview.webrtc.org/2888093004/ )
>
> Reason for revert:
> Breaks bot on chromium.webrtc.fyi.
>
> Original issue's description:
> > Removes usage of native base::android::GetApplicationContext()
> >
> > BUG=webrtc:7665
> >
> > Review-Url: https://codereview.webrtc.org/2888093004
> > Cr-Commit-Position: refs/heads/master@{#18195}
> > Committed: bc83e2ee69
>
> TBR=magjed@webrtc.org,henrika@webrtc.org
> # Skipping CQ checks because original CL landed less than 1 days ago.
> NOPRESUBMIT=true
> NOTREECHECKS=true
> NOTRY=true
> BUG=webrtc:7665
>
> Review-Url: https://codereview.webrtc.org/2894593002
> Cr-Commit-Position: refs/heads/master@{#18196}
> Committed: 40d224814a

BUG=webrtc:7665

Review-Url: https://codereview.webrtc.org/2889183002
Cr-Commit-Position: refs/heads/master@{#18235}
2017-05-23 14:34:17 +00:00
868f32f423 AudioProcessingModule has a feature to make a recording of its
configuration, inputs and outputs over a period of time. It is
activated by AudioProcessing::StartRecording. The data is stored in
binary protobuf format in a specified file. The file IO is, as of
this CL, done from the real-time audio thread.

This CL contains an interface for AecDump, a new APM submodule that
will handle the recordings. Calls to the new interface from the
AudioProcessingModule are added. These calls have no effect, and for a
short while, audio_processing_impl.cc will contain two copies of
recording calls.

The original calls are guarded by the WEBRTC_AUDIOPROC_DEBUG_DUMP
preprocessor define. They still have an effect, while the new ones do
not. In the following CLs, the old recording calls will be removed,
and an implementation of AecDump added.

The reasons for the refactoring is to move file IO operations from the
real-time audio thread, to add a top-level low-priority task queue for
logging tasks like this, to simplify and modularize audio_processing_impl.cc
and remove some of the preprocessor directives. These goals will be
archived by the upcoming CLs. The implementation is in
https://codereview.webrtc.org/2865113002.

BUG=webrtc:7404

Review-Url: https://codereview.webrtc.org/2778783002
Cr-Commit-Position: refs/heads/master@{#18233}
2017-05-23 14:20:05 +00:00
23ac8b49f4 Preserve level controller output when no other effects are active
This CL ensures that the output of the level controller is kept
when no other submodules in APM are active

BUG=webrtc:7697,

Review-Url: https://codereview.webrtc.org/2902723002
Cr-Commit-Position: refs/heads/master@{#18230}
2017-05-23 12:33:56 +00:00
1d68089f4b Transparency increasing tuning for AEC3.
This CL increases the transparency of the AEC3 via tuning.
The major changes are
1) Limiting the suppression gain to the 16 bit sample floor.
2) Controlling the rate of the suppression gain increase
   according to the signal characteristics.

Apart from these tunings, the code for the suppression gain
was refactored to increase/maintain the code quality after
the above changes.

BUG=webrtc:7519,webrtc:7528, chromium:715893

Review-Url: https://codereview.webrtc.org/2886733002
Cr-Commit-Position: refs/heads/master@{#18229}
2017-05-23 11:07:10 +00:00
5e171752a2 Reland of use allocated encoders in SimulcastEncoderAdapter. (patchset #1 id:1 of https://codereview.webrtc.org/2893003002/ )
Reason for reland:
Chrome encoder implementation fixed.

Original issue's description:
> Revert of Reuse allocated encoders in SimulcastEncoderAdapter. (patchset #15 id:320001 of https://codereview.webrtc.org/2830793005/ )
>
> Reason for revert:
> Breaks Chrome tests.
>
> Original issue's description:
> > Reuse allocated encoders in SimulcastEncoderAdapter.
> >
> > Prior to this change, the SimulcastEncoderAdapter would destroy and create
> > encoders whenever it is being reinitialized. After this change, the
> > SimulcastEncoderAdapter will cache the already allocated encoders, and reuse
> > them after reinitialization.
> >
> > This change will help in reducing the number of PictureID "jumps" that have
> > been seen around encoder reinitialization.
> >
> > TESTED=AppRTCMobile, Chrome desktop, and internal app, with forced encoder reinits every 30 frames and https://codereview.webrtc.org/2833493003/ applied.
> > BUG=webrtc:7475
> >
> > Review-Url: https://codereview.webrtc.org/2830793005
> > Cr-Commit-Position: refs/heads/master@{#18215}
> > Committed: 0b8bfb9d98
>
> TBR=stefan@webrtc.org,noahric@chromium.org,glaznev@webrtc.org,sprang@webrtc.org
> # Skipping CQ checks because original CL landed less than 1 days ago.
> NOPRESUBMIT=true
> NOTREECHECKS=true
> NOTRY=true
> BUG=webrtc:7475
>
> Review-Url: https://codereview.webrtc.org/2893003002
> Cr-Commit-Position: refs/heads/master@{#18216}
> Committed: 56e119e2e8

TBR=stefan@webrtc.org,noahric@chromium.org,glaznev@webrtc.org,sprang@webrtc.org
# Not skipping CQ checks because original CL landed more than 1 days ago.
BUG=webrtc:7475

Review-Url: https://codereview.webrtc.org/2901493002
Cr-Commit-Position: refs/heads/master@{#18228}
2017-05-23 10:32:16 +00:00
3ec96df907 This CL introduces a new APM sub-module named AGC2 that does not use the band
split domain and only implements floating point operations (to avoid spectral
leakage issues and unnecessary complexity).

The goal of this CL is adding the new sub-module into APM without providing an
implementation that could replace the existing gain control modules. The focus
is in fact on initialization, reset, and configuration of AGC2.

The module itself only applies a hard-coded gain value. This behavior will
change in the coming CLs.

BUG=webrtc:7494

Review-Url: https://codereview.webrtc.org/2848593002
Cr-Commit-Position: refs/heads/master@{#18222}
2017-05-22 13:57:06 +00:00
b2c001a795 Update Packet::GetHeader() to copy playout_delay
Packet::GetHeader() wasn't copying playout_delay. As result
playout_delay was ignored when flexfec is enabled.

Patch by Rob McCool <rmccool@google.com>

BUG=webrtc:7590

Review-Url: https://codereview.webrtc.org/2899553003
Cr-Commit-Position: refs/heads/master@{#18218}
2017-05-20 21:16:52 +00:00
56e119e2e8 Revert of Reuse allocated encoders in SimulcastEncoderAdapter. (patchset #15 id:320001 of https://codereview.webrtc.org/2830793005/ )
Reason for revert:
Breaks Chrome tests.

Original issue's description:
> Reuse allocated encoders in SimulcastEncoderAdapter.
>
> Prior to this change, the SimulcastEncoderAdapter would destroy and create
> encoders whenever it is being reinitialized. After this change, the
> SimulcastEncoderAdapter will cache the already allocated encoders, and reuse
> them after reinitialization.
>
> This change will help in reducing the number of PictureID "jumps" that have
> been seen around encoder reinitialization.
>
> TESTED=AppRTCMobile, Chrome desktop, and internal app, with forced encoder reinits every 30 frames and https://codereview.webrtc.org/2833493003/ applied.
> BUG=webrtc:7475
>
> Review-Url: https://codereview.webrtc.org/2830793005
> Cr-Commit-Position: refs/heads/master@{#18215}
> Committed: 0b8bfb9d98

TBR=stefan@webrtc.org,noahric@chromium.org,glaznev@webrtc.org,sprang@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=webrtc:7475

Review-Url: https://codereview.webrtc.org/2893003002
Cr-Commit-Position: refs/heads/master@{#18216}
2017-05-19 17:33:03 +00:00
0b8bfb9d98 Reuse allocated encoders in SimulcastEncoderAdapter.
Prior to this change, the SimulcastEncoderAdapter would destroy and create
encoders whenever it is being reinitialized. After this change, the
SimulcastEncoderAdapter will cache the already allocated encoders, and reuse
them after reinitialization.

This change will help in reducing the number of PictureID "jumps" that have
been seen around encoder reinitialization.

TESTED=AppRTCMobile, Chrome desktop, and internal app, with forced encoder reinits every 30 frames and https://codereview.webrtc.org/2833493003/ applied.
BUG=webrtc:7475

Review-Url: https://codereview.webrtc.org/2830793005
Cr-Commit-Position: refs/heads/master@{#18215}
2017-05-19 13:51:42 +00:00
e87c87651f Check H264 NALUs for frametype and insert SPS/PPS packets into the PacketBuffer.
BUG=chromium:719095

Review-Url: https://codereview.webrtc.org/2889163003
Cr-Commit-Position: refs/heads/master@{#18214}
2017-05-19 13:38:50 +00:00
30df64f143 Update plot_webrtc_test_logs.py:
- Add codec_type-implementation_name label option.
- Update figure title to exclude information that exist in legend.
- Change frame info in title from: # of frames in file -> # of processed frames.

BUG=webrtc:6634

Review-Url: https://codereview.webrtc.org/2890223002
Cr-Commit-Position: refs/heads/master@{#18209}
2017-05-19 11:07:38 +00:00
ce4d91527a Avoid render resampling when there is no need for render signal analysis.
This CL adjusts the render processing rate such to avoid resampling of the
render signal when that is not needed.
Note that to avoid acquiring more locks than needed, this should be achieved
during initialization.

BUG=webrtc:7667

Review-Url: https://codereview.webrtc.org/2887693002
Cr-Commit-Position: refs/heads/master@{#18207}
2017-05-19 08:28:05 +00:00
93e4522105 Renaming probing_interval to bwe_period globally.
probing_interval as a name is used for the period that BWE attempt to increase its estimate. The name is confusing since it is not related to "probing" which is a special mechanism for estimating BWE.

BUG=None

Review-Url: https://codereview.webrtc.org/2888893002
Cr-Commit-Position: refs/heads/master@{#18203}
2017-05-18 21:32:41 +00:00
8eef7aa7cf Add DesktopRectTest for UnionWith() function
DesktopRect::UnionWith() function has been added by change
https://codereview.webrtc.org/2845213002. This change adds test cases to cover
the newly added logic. More specifically, union between an empty rectangle and a
non-empty one or two empty rectangles.

BUG=webrtc:7541

Review-Url: https://codereview.webrtc.org/2891593003
Cr-Commit-Position: refs/heads/master@{#18201}
2017-05-18 19:27:16 +00:00
3184f8e329 Dont request keyframes if the stream is inactive or if we are currently receiving a keyframe.
BUG=webrtc:7520

Review-Url: https://codereview.webrtc.org/2853503002
Cr-Commit-Position: refs/heads/master@{#18199}
2017-05-18 15:08:53 +00:00
40d224814a Revert of Removes usage of native base::android::GetApplicationContext() (patchset #6 id:120001 of https://codereview.webrtc.org/2888093004/ )
Reason for revert:
Breaks bot on chromium.webrtc.fyi.

Original issue's description:
> Removes usage of native base::android::GetApplicationContext()
>
> BUG=webrtc:7665
>
> Review-Url: https://codereview.webrtc.org/2888093004
> Cr-Commit-Position: refs/heads/master@{#18195}
> Committed: bc83e2ee69

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

Review-Url: https://codereview.webrtc.org/2894593002
Cr-Commit-Position: refs/heads/master@{#18196}
2017-05-18 13:44:20 +00:00
bc83e2ee69 Removes usage of native base::android::GetApplicationContext()
BUG=webrtc:7665

Review-Url: https://codereview.webrtc.org/2888093004
Cr-Commit-Position: refs/heads/master@{#18195}
2017-05-18 13:28:45 +00:00
539107175a Break backwards traversal loop if we have looped around all packets in the PacketBuffer for H264 frames.
BUG=webrtc:7532

Review-Url: https://codereview.webrtc.org/2868723003
Cr-Commit-Position: refs/heads/master@{#18191}
2017-05-18 09:24:40 +00:00
855aeead57 Updated comments for unit tests to validate iOS audio session isInterrupted flag does not get reset correctly.
BUG=webrtc:7605

Review-Url: https://codereview.webrtc.org/2886183002
Cr-Commit-Position: refs/heads/master@{#18188}
2017-05-17 19:37:17 +00:00
1592c74d8a Add log message to help analyze why echo likelihood > 1.1
This CL adds a log message with the relevant part of the internal state of the echo detector to the text log when this unexpected scenario occurs.

BUG=b/38014838

Review-Url: https://codereview.webrtc.org/2883283002
Cr-Commit-Position: refs/heads/master@{#18185}
2017-05-17 16:53:02 +00:00
76a5593835 Don't add FEC and RTX overheads when calculating a padding packet's maximum payload size.
BUG=webrtc:7433

Review-Url: https://codereview.webrtc.org/2892583002
Cr-Commit-Position: refs/heads/master@{#18184}
2017-05-17 14:50:17 +00:00