Commit Graph

216 Commits

Author SHA1 Message Date
26f78f7ecb Adding temporal layer strategy that keeps base layer framerate at an acceptable value.
R=stefan@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4911 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-10-03 14:06:14 +00:00
572699d3eb Propagate AutoMuter interface out to VideoCodingModule
BUG=2436
R=stefan@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4878 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-09-30 12:16:08 +00:00
30377c7f71 Change the parameters of calculating maximum decode time.
- Reduce the window size from 20 to 10 seconds. If there is
  any spurious high decode time, it will be faster to pass it.
- Ignore more samples at first because HW decoder has higher
  initialization latency.

BUG=crbug.com/298176
TEST=Run apprtc loopback on Chromebook Daisy.
R=stefan@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4874 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-09-28 06:06:18 +00:00
544b17c6a9 Implemented AutoMuter in MediaOptimization
Also added a unittest. This is the first step towards creating an
AutoMuter function in WebRTC.

R=mflodman@webrtc.org, stefan@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4857 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-09-26 12:05:15 +00:00
054ccd2e35 Remove include_dirs from video_coding.
BUG=1662
TEST=compile on trybots
R=stefan@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4853 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-09-26 09:22:09 +00:00
641587f938 Disable some VP8 tests on Android.
DecodeWithACompleteKeyFrame and FixedTemporalLayersStrategy.

TBR=andresp
BUG=2037

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4829 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-09-24 18:43:28 +00:00
b426c469b9 MediaOptimization: Converting a few members to scoped_ptrs
For consistency with other parts of the code.

R=stefan@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4822 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-09-24 07:41:53 +00:00
bec11ef632 Reformatting media_optimization.cc and .h
Ran both tools/refactoring/webrtc_reformat.py and clang-format.
Changing VCMMediaOptimization -> MediaOptimization and
VCMEncodedFrameSample -> EncodedFrameSample.
Aligning the order of methods in .h and .cc files and fixing comments.

R=stefan@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4816 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-09-23 19:54:25 +00:00
98fcd2d4c3 Adding unit tests for default temporal layer strategy.
R=mflodman@webrtc.org, stefan@webrtc.org, stefan

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4810 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-09-23 11:12:59 +00:00
4f3624d39e Avoid recursively taking critical section.
TEST=trybots
BUG=2261
R=pbos@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4800 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-09-20 07:43:17 +00:00
8db81c5112 Fix races in vcm::Process().
R=pbos@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4775 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-09-18 11:57:34 +00:00
32d640e03d Fix typo in r4765.
Fixes compile error on all platforms.

BUG=
TEST=compile on tryboys
R=stefan@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4766 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-09-17 10:36:30 +00:00
da2c4cede0 Fix dangling pointer _encoder in video_sender.cc.
When _codecDataBase.SetSendCodec() fails, the encoder may be deleted.
This is however not reflected in _encoder, which then becomes a dangling
pointer to the deleted object.

BUG=2384
R=stefan@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4765 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-09-17 09:38:41 +00:00
e401c2e391 Split video coding module unit tests into sender and receiver unit tests.
R=mflodman@webrtc.org, stefan@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4753 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-09-16 20:29:13 +00:00
f7eb75be1a Split VideoCodingModuleImpl into VideoSender and VideoReceiver.
Only implmentation is changed the interface to the module is unchanged for now.

R=mikhal@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4746 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-09-14 00:25:28 +00:00
1f09dbe353 Moving test-only code (stream_generator) out of vcm implemention.
R=niklas.enbom@webrtc.org, stefan@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4740 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-09-13 19:17:54 +00:00
d4d59ac871 Remove FrameForStorage:Follow up on r4688
R=stefan@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4723 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-09-11 15:18:15 +00:00
554d158ce6 Reset jitter buffer and timing if frames are getting too much delay.
BUG=chromium/263867
TEST=trybots
R=mikhal@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4721 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-09-11 08:45:26 +00:00
021c42bfa8 Lock use of _packetRequestCallback in VCM.
BUG=
R=stefan@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4708 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-09-09 17:18:31 +00:00
0181b5f8dd ExternalVideoDecoder for new VideoEngine API.
Implements the ExternalVideoDecoder interface for VideoReceiveStream.
Also adds a FakeDecoder used in tests, removing the overhead of running
the EngineTest tests with VP8 under Memcheck/TSan, allowing us to enable
them under Memcheck/TSan as well.

BUG=2346,2312
R=stefan@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4702 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-09-09 08:26:30 +00:00
7bb8f02274 Adds support for combining RTX and FEC/RED.
This is accomplished by breaking out RTX and FEC/RED functionality from the RTP module and keeping track of the base payload type, that is the payload type received when not receiving RTX.

Enables retransmissions over RTX by default in the loopback test.

BUG=1811
TESTS=voe/vie_auto_test --automated and trybots.
R=mflodman@webrtc.org, pbos@webrtc.org, xians@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4692 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-09-06 13:40:11 +00:00
5500d93fe5 Add temporal layer factory.
R=marpan@google.com, stefan@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4691 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-09-06 11:26:15 +00:00
f1e807c0e5 Removing FrameForStorage
R=pwestin@webrtc.org, stefan@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4688 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-09-05 22:34:41 +00:00
9080518a39 Restore severity precondition to logging.h.
I mistakenly ommitted the checks when logging.h was ported from
libjingle to webrtc. This caused a significant CPU cost for logs which
were later filtered out anyway.

Verified with LS_VERBOSE logging in neteq4, running:
$ out/Release/modules_unittests \
--gtest_filter=NetEqDecodingTest.TestBitExactness \
--gtest_repeat=50 > time.txt
$ grep "case ran" time.txt | grep "[0-9]* ms" -o | sort

Results on a MacBook Retina, averaged over 5 runs:
Verbose logs disabled:                          666 ms
Exisiting implementation, verbose logs enabled: 944 ms (1.42x)
New implementation, verbose logs enabled:       673 ms (1.01x)

BUG=2314
R=henrik.lundin@webrtc.org, henrike@webrtc.org, kjellander@webrtc.org, turaj@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4682 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-09-05 16:40:43 +00:00
3c5a9242fe Don't force cont' when enabling kWithErrors
BUG=
R=pbos@webrtc.org, stefan@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4669 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-09-03 20:45:36 +00:00
2b810bf77b Removing non decodable count from session info: This value isn't used, and therfore can be removed. This is a step towards the refactor of the session info to use maps.
R=stefan@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4667 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-09-03 19:09:49 +00:00
f31a47abdc VCM:Accounting for bounds when inserting packets. We currently receive indicators to the first and last packets of the frame, but not have any sanity to verify that all packets are indeed within the bounds (when available). This cl attempts to fix that,
BUG=
R=marpan@google.com

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4614 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-08-26 17:10:11 +00:00
b2c28c3699 Relanding 4597 - Don't force key frame when decoding with errors.
Makes sure that incomplete key frame or delta frames will be released from the JB when decoding with errors.
The decoder in turn will trigger a PLI until a complete key frame is received in order to start a session.

TBR=stefan@webrtc.org

BUG=

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4607 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-08-23 21:54:50 +00:00
ceea41d135 Revert 4597 "Don't force key frame when decoding with errors"
> Don't force key frame when decoding with errors
> 
> BUG=2241
> R=stefan@webrtc.org
> 
> Review URL: https://webrtc-codereview.appspot.com/2036004

TBR=mikhal@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4600 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-08-23 00:53:24 +00:00
44af55cc44 Don't force key frame when decoding with errors
BUG=2241
R=stefan@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4597 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-08-22 23:29:43 +00:00
dbf6a81cb5 Follow-up changes to kSelectiveErrors
Committing cl for agalusza (cl 1992004)
TEST = trybots
R=marpan@google.com

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4587 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-08-21 20:40:47 +00:00
822fbd8b68 Update talk to 50918584.
Together with Stefan's http://review.webrtc.org/1960004/.

R=mallinath@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4556 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-08-15 23:38:54 +00:00
dde7d4c6ed Roll chromium_revision 214260:217707 and gflags 45:84
gflags roll is needed mostly to pick up fixes for warnings triggered by newer
compiler/settings pulled in by the chromium roll.  Had to switch from the old
google-gflags project the current gflags project to pick up this fix (see
https://code.google.com/p/gflags/source/detail?r=74 for details).

Update android build.xml file to reflect tools moves in new SDK pulled in by the chromium_revision roll.

R=niklas.enbom@webrtc.org, wu@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4555 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-08-15 23:31:30 +00:00
0d94c2f81c Avoid acquiring VCM::_receiveCritSect during decode callback.
When VideoDecoder::Decode, Reset, or Release is called,
VideoCodingModuleImpl::_receiveCritSect may have been
acquired. Decode callback needs to acquire the same lock
in ViEChannel::FrameToRender. It is not a problem for
SW decode because decode callback is run on the same
WebRTC decoding thread and the lock is re-entrant. But
for HW decode, decode callback is run on a thread different
from WebRTC decoding thread. Decode callback gets the locks
in the opposite order. Deadlock can happen.

BUG=http://crbug.com/170345
TEST=Try apprtc.appspot.com/?debug=loopback on ARM Chromebook Daisy.
     Run libjingle_peerconnection_unittest.

R=stefan@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4523 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-08-12 14:20:49 +00:00
a3b7406219 Remove unused unreferenced code in webrtc/
The code removed here are .c, .cc and .h files that are not referenced
from anywhere else. E.g. if git-grep showed no occurrence of the file
it's removed. This process was repeated until no more unreferenced
files were present.

BUG=
R=andrew@webrtc.org, henrike@webrtc.org, phoglund@webrtc.org, stefan@webrtc.org, turaj@webrtc.org, wu@webrtc.org, xians@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4511 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-08-09 08:47:51 +00:00
64799da6c6 Allowing decoding with errors, when disabling nack.
BUG=1897
R=stefan@webrtc.org, wu@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4508 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-08-08 22:45:33 +00:00
d177c10e2d Added logic for kSelectiveErrors to VCMJitterBuffer and corresponding unit tests.
R=marpan@google.com, mikhal@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4503 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-08-08 01:12:33 +00:00
c4e1ab515b Added Decoding with errors API to video_coding.h and removed unused DecodeError enum.
R=marpan@google.com, mikhal@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4497 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-08-06 18:27:41 +00:00
12dc1a38ca Switch C++-style C headers with their C equivalents.
The C++ headers define the C functions within the std:: namespace, but
we mainly don't use the std:: namespace for C functions. Therefore we
should include the C headers.

BUG=1833
R=tommi@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4486 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-08-05 16:22:53 +00:00
89c674053e Adds all unittests to android NDK-APK framework.
BUG=N/A
R=andrew@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4474 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-08-02 16:53:47 +00:00
a7e360e89b Removed lines preventing simultaneous kHardNack and decoding with errors. Also made changes recommended by gcl lint (with the exception of changing non-const references to pointers).
Propagated orthogonal API for decoding with errors from VideoCodingModule to VCMJitterBuffer.
Modified VCMJitterBuffer to allow three error modes: kNoErrors, kSelectiveErrors, kWithErrors.

R=marpan@google.com, mikhal@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4463 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-08-01 03:15:08 +00:00
7f7162a003 Fix some chromium-style warnings in webrtc/modules/video_coding/
BUG=163
R=mikhal@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4429 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-07-30 15:18:31 +00:00
d818dcb939 Sets up framework for decoding with errors: collects frame sizes (in number of packets) in JB and passes this information to VCMSessionInfo with rtt_ms as FrameData.
R=marpan@google.com, mikhal@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4424 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-07-29 21:48:11 +00:00
d2102afa2a Undo libvpx include changes in r4348 to fix build.
A longer term fix is needed, but this at least quickly unblocks the build.

R=pbos@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4367 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-07-17 18:48:24 +00:00
aa4d96a134 Revert r4301
R=mikhal@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4357 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-07-16 19:25:04 +00:00
a4407329d4 Include files from webrtc/.. paths in video_coding/.
BUG=1662
R=tommi@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4348 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-07-16 12:32:05 +00:00
1a7b9b94be Cleanup WebRTC tracing
The goal of this change is to:
1. Remove unused tracing events.
2. Organize tracing events to facilitate measurement of end to end latency.

The major change in this CL is to use ASYNC_STEP such that operation
flow can be traced for the same frame.

R=marpan@webrtc.org, pwestin@webrtc.org, turaj@webrtc.org, wu@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4308 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-07-08 21:31:18 +00:00
a950300b0e Disables unit tests that don't work on Android for Android.
BUG=N/A
R=andrew@webrtc.org, kjellander@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4306 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-07-08 18:53:54 +00:00
66b2e5c05a Breaking out receive-stats, rtp-payload-registry and rtp-receiver from the
rtp_rtcp implementation.

This refactoring significantly reduces the receive-side RTP parser and receiver
complexity, and makes it possible to implement RTX correctly by having two
instances of receive-statistics.

With this change the dead-or-alive and packet timeout APIs are removed.

TEST=trybots, vie_auto_test, voe_auto_test
BUG=1811
R=mflodman@webrtc.org, pbos@webrtc.org, xians@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4301 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-07-05 14:30:48 +00:00
d900e8bea8 Proper spacing for end-of-namespace comments.
BUG=
R=mflodman@webrtc.org, tina.legrand@webrtc.org

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@4293 4adac7df-926f-26a2-2b94-8c16560cd09d
2013-07-03 15:12:26 +00:00