Commit Graph

54 Commits

Author SHA1 Message Date
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
c3372583d4 Revert of Deliver video frames on Android, on the decode thread. (patchset #7 id:120001 of https://codereview.webrtc.org/2764573002/ )
Reason for revert:
Breaks Chrome FYI Android bots.

See:
https://build.chromium.org/p/chromium.webrtc.fyi/builders/Android%20Tests%20%28dbg%29%20%28L%20Nexus9%29/builds/20418
https://build.chromium.org/p/chromium.webrtc.fyi/builders/Android%20Tests%20%28dbg%29%20%28L%20Nexus6%29/builds/14724
https://build.chromium.org/p/chromium.webrtc.fyi/builders/Android%20Tests%20%28dbg%29%20%28L%20Nexus5%29/builds/20133
https://build.chromium.org/p/chromium.webrtc.fyi/builders/Android%20Tests%20%28dbg%29%20%28K%20Nexus5%29/builds/15111

Original issue's description:
> Deliver video frames on Android, on the decode thread.
>
> VideoCoding
> * Adding a method for polling for frames on Android only until the capture implementation takes care of this (longer term plan).
>
> CodecDatabase
> * Add an accessor for the current decoder
> * Use std::unique_ptr<> for ownership.
> * Remove "Release()" and "ReleaseDecoder()". Instead just delete.
> * Remove |friend| relationship between CodecDatabase and VCMGenericDecoder.
>
> VCMDecodedFrameCallback
> * DCHECKs for thread correctness.
> * Remove |lock_| now that a threading model has been established and verified.
>
> VCMGenericDecoder
> * All methods now have thread checks.
> * Variable access associated with thread checkers.
>
> VideoReceiver
> * Added two notification methods, DecoderThreadStarting() and DecoderThreadStopped()
>   * Allows us to establish a period when the decoder thread is not running and it is safe to modify variables such as callbacks, that are only read when the decoder thread is running.
>   * Allows us to DCHECK thread guarantees.
>   * Allows synchronizing callbacks from the module process thread and have them only active while the decoder thread is running.
>   * The above, allows us to establish two modes for the thread, single-threaded-mutable and multi-threaded-const.
>   * Using that knowledge, we can remove |receive_crit_| as well as locking for a number of member variables.
>
> MediaCodecVideoDecoder
> * Removed frame polling code from this class, since this is now done from the root thread function in VideoReceiveStream.
>
> VideoReceiveStream
> * On Android: Polls for decoded frames every 10ms (same interval as previously in MediaCodecVideoDecoder)
> * [Un]Registers the |video_receiver_| with the module thread only around the time the decoder thread is started/stopped.
> * Notifies the receiver of start/stop events of the decoder thread.
> * Changed the decoder thread to use the new PlatformThread callback type.
>
> BUG=webrtc:7361, 695438
>
> Review-Url: https://codereview.webrtc.org/2764573002
> Cr-Commit-Position: refs/heads/master@{#17527}
> Committed: e3aa88bbd5

TBR=sakal@webrtc.org,mflodman@webrtc.org,stefan@webrtc.org,tommi@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=webrtc:7361, 695438

Review-Url: https://codereview.webrtc.org/2792033003
Cr-Commit-Position: refs/heads/master@{#17530}
2017-04-04 14:16:21 +00:00
e3aa88bbd5 Deliver video frames on Android, on the decode thread.
VideoCoding
* Adding a method for polling for frames on Android only until the capture implementation takes care of this (longer term plan).

CodecDatabase
* Add an accessor for the current decoder
* Use std::unique_ptr<> for ownership.
* Remove "Release()" and "ReleaseDecoder()". Instead just delete.
* Remove |friend| relationship between CodecDatabase and VCMGenericDecoder.

VCMDecodedFrameCallback
* DCHECKs for thread correctness.
* Remove |lock_| now that a threading model has been established and verified.

VCMGenericDecoder
* All methods now have thread checks.
* Variable access associated with thread checkers.

VideoReceiver
* Added two notification methods, DecoderThreadStarting() and DecoderThreadStopped()
  * Allows us to establish a period when the decoder thread is not running and it is safe to modify variables such as callbacks, that are only read when the decoder thread is running.
  * Allows us to DCHECK thread guarantees.
  * Allows synchronizing callbacks from the module process thread and have them only active while the decoder thread is running.
  * The above, allows us to establish two modes for the thread, single-threaded-mutable and multi-threaded-const.
  * Using that knowledge, we can remove |receive_crit_| as well as locking for a number of member variables.

MediaCodecVideoDecoder
* Removed frame polling code from this class, since this is now done from the root thread function in VideoReceiveStream.

VideoReceiveStream
* On Android: Polls for decoded frames every 10ms (same interval as previously in MediaCodecVideoDecoder)
* [Un]Registers the |video_receiver_| with the module thread only around the time the decoder thread is started/stopped.
* Notifies the receiver of start/stop events of the decoder thread.
* Changed the decoder thread to use the new PlatformThread callback type.

BUG=webrtc:7361, 695438

Review-Url: https://codereview.webrtc.org/2764573002
Cr-Commit-Position: refs/heads/master@{#17527}
2017-04-04 10:53:02 +00:00
a5c18d7312 Delete video_coding_robustness_unittest.cc
BUG=none

Review-Url: https://codereview.webrtc.org/2755803004
Cr-Commit-Position: refs/heads/master@{#17312}
2017-03-20 17:43:23 +00:00
05e908b10b Delete unused method VideoCodingModule::DiscardedPackets().
This method isn't called and the value it represents, is made available
via the stats APIs.

BUG=none

Review-Url: https://codereview.webrtc.org/2760613002
Cr-Commit-Position: refs/heads/master@{#17287}
2017-03-17 12:48:24 +00:00
b1db3702f7 Delete unsupported method VideoCodingModule::RegisterDecoderTimingCallback.
The implementation behind this method has been a noop for a long time.

BUG=none

Review-Url: https://codereview.webrtc.org/2757843002
Cr-Commit-Position: refs/heads/master@{#17286}
2017-03-17 12:35:43 +00:00
275e2099ab Remove ReceiveCodec() getters from VideoCodingModule.
The getters are not used and the implementation cannot be guaranteed
to return a correct value except when called synchronously from
the decoding thread while decoding.

The methods as is imply that the implementation needs to offer some
sort of synchronization, and that's not desirable.

BUG=webrtc:7328
R=stefan@webrtc.org

Review-Url: https://codereview.webrtc.org/2741853008 .
Cr-Commit-Position: refs/heads/master@{#17233}
2017-03-14 18:55:19 +00:00
cd386eb13f Delete support for sending RTCP RPSI and SLI messages.
BUG=webrtc:7338

Review-Url: https://codereview.webrtc.org/2746413003
Cr-Commit-Position: refs/heads/master@{#17229}
2017-03-14 15:54:43 +00:00
d0a71ba1ae Updates to VCMDecodedFrameCallback, VideoReceiver and a few related classes/tests.
* The _receiveCallback member of VCMDecodedFrameCallback does actually not require locking now that the threading model is slightly clearer. Documentation and checks have been added.
* UserReceiveCallback() never returns null and must always be called on the decoder thread. Checks have been added and the two test suites that were failing to set this callback, have been fixed and a new mock class added.  (looks like sakal@ may have hit some issues with flaky tests there).
* Changed VcmPayloadSink to use move semantics which I suspect was the intention at the time the code was written (when we didn't have move semantics).
* Added thread checker to a couple of classes and started adding thread checks for known behavior.  There's more to be  done there.
* Remove the |_decoder| member variable in VideoReceiver. It is not needed and as it could be used, left us open to a race.
* TODOs added for places where we can reduce locking. I suspect that we can get away with not needing a lock around _codecDataBase in VideoReceiver once we've got a clear picture of the threading model and ensured that all adhere to it.

BUG=webrtc:7328

Review-Url: https://codereview.webrtc.org/2744013002
Cr-Commit-Position: refs/heads/master@{#17226}
2017-03-14 11:16:20 +00:00
a8d8aadba8 Refactor + enable GN check on video_coding_utility
To avoid the cyclic dependency

BUG=webrtc:6828
NOTRY=True
TBR=magjed@webrtc.org

Review-Url: https://codereview.webrtc.org/2717113002
Cr-Commit-Position: refs/heads/master@{#17116}
2017-03-08 13:42:26 +00:00
721d402d71 Create VideoReceiver with external VCMTiming object.
In order for the VCMTiming object to be correctly updated with decoding timings
when running the WebRTC-NewVideoJitterBuffer experiment the VCMTiming object
has to be available in both the VideoReceiver and the video_coding::FrameBuffer
class. Therefore the VCMTiming object is created in VideoRecieveStream and
then passed to VideoReceiver/video_coding::FrameBuffer as they are constructed.

BUG=webrtc:5514

Review-Url: https://codereview.webrtc.org/2575473004
Cr-Commit-Position: refs/heads/master@{#15638}
2016-12-15 15:11:01 +00:00
1a646ee522 Wire up BitrateAllocation to be sent as RTCP TargetBitrate
This is the video parts of https://codereview.webrtc.org/2531383002/
Wire up BitrateAllocation to be sent as RTCP TargetBitrate

BUG=webrtc:6301

Review-Url: https://codereview.webrtc.org/2541303003
Cr-Commit-Position: refs/heads/master@{#15359}
2016-12-01 14:34:18 +00:00
876222f77d Move usage of QualityScaler to ViEEncoder.
This brings QualityScaler much more in line with OveruseFrameDetector.
The two classes are conceptually similar, and should be used in the
same way. The biggest changes in this CL are:
- Quality scaling is now only done in ViEEncoder and not in each
  encoder implementation separately.
- QualityScaler now checks the average QP asynchronously, instead of
  having to be polled on each frame.
- QualityScaler is no longer responsible for actually scaling the frames,
  but has a callback to ViEEncoder that it uses to express it's desire
  for lower resolution.

BUG=webrtc:6495

Review-Url: https://codereview.webrtc.org/2398963003
Cr-Commit-Position: refs/heads/master@{#15286}
2016-11-29 09:44:22 +00:00
40217c3718 Initial rate allocation should not use fps = 0
A recent cl (https://codereview.webrtc.org/2510583002) introduced an
issue where the initial rate allocation (call to VideoBitrateAllocator
and any associated temporal layers) uses framerate = 0 fps. This may
cause issues, including having the rate control in ScreenshareLayers
ramp up too slowly.

This CL make the initial call use VideoCodec.maxFramerate as framerate.
Also expanded unit tests.

BUG=webrtc:6301

Review-Url: https://codereview.webrtc.org/2513383002
Cr-Commit-Position: refs/heads/master@{#15166}
2016-11-21 13:42:04 +00:00
08127a9449 Reland #2 of Issue 2434073003: Extract bitrate allocation ...
This is yet another reland of https://codereview.webrtc.org/2434073003/
including two fixes:

1. SimulcastRateAllocator did not handle the screenshare settings properly for numSimulcastStreams = 1. Additional test case was added for that.
2. In VideoSender, when rate allocation is updated after setting a new VideoCodec config, only update the state of the EncoderParameters, but don't actually run SetRateAllocation on the encoder itself. This caused some problems upstreams.

Please review only the changes after patch set 1.

Original description:

Extract bitrate allocation of spatial/temporal layers out of codec impl.

This CL makes a number of intervowen changes:

* Add BitrateAllocation struct, that contains a codec independent view
  of how the target bitrate is distributed over spatial and temporal
  layers.

* Adds the BitrateAllocator interface, which takes a bitrate and frame
  rate and produces a BitrateAllocation.

* A default (non layered) implementation is added, and
  SimulcastRateAllocator is extended to fully handle VP8 allocation.
  This includes capturing TemporalLayer instances created by the
  encoder.

* ViEEncoder now owns both the bitrate allocator and the temporal layer
  factories for VP8. This allows allocation to happen fully outside of
  the encoder implementation.

This refactoring will make it possible for ViEEncoder to signal the
full picture of target bitrates to the RTCP module.

BUG=webrtc:6301
R=stefan@webrtc.org

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

Cr-Commit-Position: refs/heads/master@{#15105}
2016-11-16 15:41:45 +00:00
fd5a20fd68 New jitter buffer experiment.
BUG=webrtc:5514

Review-Url: https://codereview.webrtc.org/2480293002
Cr-Commit-Position: refs/heads/master@{#15077}
2016-11-15 08:58:06 +00:00
1369c83b42 Revert of Issue 2434073003: Extract bitrate allocation ... (patchset #4 id:60001 of https://codereview.webrtc.org/2488833004/ )
Reason for revert:
Seems to be causing flakiness in perf test:
FullStackTest.ScreenshareSlidesVP8_2TL_LossyNet

Original issue's description:
> Reland of Issue 2434073003: Extract bitrate allocation ...
>
> This is a reland of https://codereview.webrtc.org/2434073003/ including
> some fixes for failing test cases.
>
> Original description:
>
> Extract bitrate allocation of spatial/temporal layers out of codec impl.
>
> This CL makes a number of intervowen changes:
>
> * Add BitrateAllocation struct, that contains a codec independent view
>   of how the target bitrate is distributed over spatial and temporal
>   layers.
>
> * Adds the BitrateAllocator interface, which takes a bitrate and frame
>   rate and produces a BitrateAllocation.
>
> * A default (non layered) implementation is added, and
>   SimulcastRateAllocator is extended to fully handle VP8 allocation.
>   This includes capturing TemporalLayer instances created by the
>   encoder.
>
> * ViEEncoder now owns both the bitrate allocator and the temporal layer
>   factories for VP8. This allows allocation to happen fully outside of
>   the encoder implementation.
>
> This refactoring will make it possible for ViEEncoder to signal the
> full picture of target bitrates to the RTCP module.
>
> BUG=webrtc:6301
>
> Committed: https://crrev.com/647bf43dcb2fd16fccf276bd94dc4400728bb405
> Cr-Commit-Position: refs/heads/master@{#15023}

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

Review-Url: https://codereview.webrtc.org/2491393002
Cr-Commit-Position: refs/heads/master@{#15026}
2016-11-10 16:30:39 +00:00
647bf43dcb Reland of Issue 2434073003: Extract bitrate allocation ...
This is a reland of https://codereview.webrtc.org/2434073003/ including
some fixes for failing test cases.

Original description:

Extract bitrate allocation of spatial/temporal layers out of codec impl.

This CL makes a number of intervowen changes:

* Add BitrateAllocation struct, that contains a codec independent view
  of how the target bitrate is distributed over spatial and temporal
  layers.

* Adds the BitrateAllocator interface, which takes a bitrate and frame
  rate and produces a BitrateAllocation.

* A default (non layered) implementation is added, and
  SimulcastRateAllocator is extended to fully handle VP8 allocation.
  This includes capturing TemporalLayer instances created by the
  encoder.

* ViEEncoder now owns both the bitrate allocator and the temporal layer
  factories for VP8. This allows allocation to happen fully outside of
  the encoder implementation.

This refactoring will make it possible for ViEEncoder to signal the
full picture of target bitrates to the RTCP module.

BUG=webrtc:6301

Review-Url: https://codereview.webrtc.org/2488833004
Cr-Commit-Position: refs/heads/master@{#15023}
2016-11-10 14:46:28 +00:00
4bc98d4e1b Revert of Extract bitrate allocation of spatial/temporal layers out of codec impl. (patchset #17 id:320001 of https://codereview.webrtc.org/2434073003/ )
Reason for revert:
Breaks perf tests.

Original issue's description:
> Extract bitrate allocation of spatial/temporal layers out of codec impl.
>
> This CL makes a number of intervowen changes:
>
> * Add BitrateAllocation struct, that contains a codec independent view
>   of how the target bitrate is distributed over spatial and temporal
>   layers.
>
> * Adds the BitrateAllocator interface, which takes a bitrate and frame
>   rate and produces a BitrateAllocation.
>
> * A default (non layered) implementation is added, and
>   SimulcastRateAllocator is extended to fully handle VP8 allocation.
>   This includes capturing TemporalLayer instances created by the
>   encoder.
>
> * ViEEncoder now owns both the bitrate allocator and the temporal layer
>   factories for VP8. This allows allocation to happen fully outside of
>   the encoder implementation.
>
> This refactoring will make it possible for ViEEncoder to signal the
> full picture of target bitrates to the RTCP module.
>
> BUG=webrtc:6301
>
> Committed: https://crrev.com/8f46c679d24a05b3f08e02c6d91ec9637f34e24f
> Cr-Commit-Position: refs/heads/master@{#14998}

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

Review-Url: https://codereview.webrtc.org/2489843002
Cr-Commit-Position: refs/heads/master@{#15001}
2016-11-09 14:14:56 +00:00
8f46c679d2 Extract bitrate allocation of spatial/temporal layers out of codec impl.
This CL makes a number of intervowen changes:

* Add BitrateAllocation struct, that contains a codec independent view
  of how the target bitrate is distributed over spatial and temporal
  layers.

* Adds the BitrateAllocator interface, which takes a bitrate and frame
  rate and produces a BitrateAllocation.

* A default (non layered) implementation is added, and
  SimulcastRateAllocator is extended to fully handle VP8 allocation.
  This includes capturing TemporalLayer instances created by the
  encoder.

* ViEEncoder now owns both the bitrate allocator and the temporal layer
  factories for VP8. This allows allocation to happen fully outside of
  the encoder implementation.

This refactoring will make it possible for ViEEncoder to signal the
full picture of target bitrates to the RTCP module.

BUG=webrtc:6301

Review-Url: https://codereview.webrtc.org/2434073003
Cr-Commit-Position: refs/heads/master@{#14998}
2016-11-09 13:09:12 +00:00
275afc5d2e Add codec name to CodecSpecificInfo and get the codec name stats from there instead.
BUG=webrtc:5687

Review-Url: https://codereview.webrtc.org/2253563002
Cr-Commit-Position: refs/heads/master@{#14012}
2016-09-01 07:21:18 +00:00
4e417b242a Reland of Switch to use SequencedTaskChecker instead of ThreadChecker where needed.
(patchset #1 id:1 of https://codereview.webrtc.org/2149553002/ )"
This reverts commit efd902cb1d9bbd81247a3e168f2080beae761d78.

Originally reviewed in https://codereview.webrtc.org/2149553002

The uptream problem should be fixed by https://codereview.webrtc.org/2145393003/

BUG=webrtc:5687
TBR=tommi@webrtc.org

Review-Url: https://codereview.webrtc.org/2152013002
Cr-Commit-Position: refs/heads/master@{#13483}
2016-07-15 06:36:00 +00:00
efd902cb1d Revert of Switch to use SequencedTaskChecker instead of ThreadChecker where needed. (patchset #1 id:1 of https://codereview.webrtc.org/2149553002/ )
Reason for revert:
Breaks Chrome FYI

https://build.chromium.org/p/chromium.webrtc.fyi/builders/Linux%20Builder/builds/8187/steps/compile/logs/stdio

Original issue's description:
> Switch to use SequencedTaskChecker instead of ThreadChecker where needed.
> This cl is in preparation for https://codereview.webrtc.org/2060403002/ Add task queue to Call.
> In the coming cl the video_sender, and i420_buffer_pool will be used on a task queue and therefore SequencedTaskChecker is needed instead of a ThreadChecker.
>
> BUG=webrtc:5687
>
> Committed: https://crrev.com/ec7cef854d85be2d9fd5b1a4e2c59a67feb662eb
> Cr-Commit-Position: refs/heads/master@{#13474}

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

Review-Url: https://codereview.webrtc.org/2150843003
Cr-Commit-Position: refs/heads/master@{#13475}
2016-07-14 09:33:25 +00:00
ec7cef854d Switch to use SequencedTaskChecker instead of ThreadChecker where needed.
This cl is in preparation for https://codereview.webrtc.org/2060403002/ Add task queue to Call.
In the coming cl the video_sender, and i420_buffer_pool will be used on a task queue and therefore SequencedTaskChecker is needed instead of a ThreadChecker.

BUG=webrtc:5687

Review-Url: https://codereview.webrtc.org/2149553002
Cr-Commit-Position: refs/heads/master@{#13474}
2016-07-14 08:32:09 +00:00
f5b2e519b4 Fix stats for encoder target bitrate when target rate is zero.
When the target bitrate is zero, currently  VideoSendStream.Stats.target_media_bitrate_bps show the last set rate before the target was set to zero.

BUG=webrtc::5687 b/29574845

Review-Url: https://codereview.webrtc.org/2122743003
Cr-Commit-Position: refs/heads/master@{#13386}
2016-07-05 15:34:08 +00:00
e15032c750 Remove all old suspension logic.
I'm also removing media_optimization_unittest.cc, since it only tested the
suspension logic and nothing else.

R=pbos@webrtc.org

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

Cr-Commit-Position: refs/heads/master@{#13355}
2016-07-01 07:00:19 +00:00
57c21f9b44 Remove ViEEncoder::Pause / Start
This cl change so that VideoSendStream::Start adds the stream as a BitrateObserver and VideoSendStream::Stop removes the stream as observer.

That also means that start will trigger a VideoEncoder::SetRate call with the most recent bitrate estimate.
VideoSendStream::Stop will trigger a VideoEncoder::SetRate with bitrate  = 0.

BUG=webrtc:5687 b/28636240

Review-Url: https://codereview.webrtc.org/2070343002
Cr-Commit-Position: refs/heads/master@{#13192}
2016-06-17 14:27:23 +00:00
Per
69b332df83 Move logic for calculating needed bitrate overhead used by NACK and FEC to VideoSender.
This cl split the class MediaOptimization into two parts. One that deals with frame dropping and stats and one new class called ProtectionBitrateCalculator that deals with  calculating the needed FEC parameters and how much of the estimated network bitrate that can be used by an encoder

Note that the logic of how FEC and the needed bitrates is not changed.

BUG=webrtc:5687
R=asapersson@webrtc.org, stefan@webrtc.org

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

Cr-Commit-Position: refs/heads/master@{#13018}
2016-06-02 13:45:53 +00:00
ad6fc5a05c Remove remaining quality-analysis (QM).
This was never turned on, contains a lot of complexity and somehow
manages triggering a bug in a downstream project.

BUG=webrtc:5066
R=marpan@webrtc.org
TBR=mflodman@webrtc.org

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

Cr-Commit-Position: refs/heads/master@{#12692}
2016-05-12 01:01:42 +00:00
600246e63f Removed SSRC knowledge from ViEEncoder.
SSRC knowledge is contained withing VideoSendStream. That also means that debug recording is moved to VideoSendStream.
I think that make sence since that allows debug recording with external encoder implementations one day.

BUG=webrtc:5687

Review-Url: https://codereview.webrtc.org/1936503002
Cr-Commit-Position: refs/heads/master@{#12632}
2016-05-04 18:26:56 +00:00
376b192ea3 Remove VideoCodingModule::VCMPacketizationCallback
And move encoder name cb to VCMSendStatisticsCallback.

BUG=webrtc:5687

Review-Url: https://codereview.webrtc.org/1900193004
Cr-Commit-Position: refs/heads/master@{#12596}
2016-05-02 18:35:33 +00:00
16ac3280f5 Remove VCMRenderBufferSizeCallback.
Unused/dead code.

BUG=
R=stefan@webrtc.org

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

Cr-Commit-Position: refs/heads/master@{#12595}
2016-05-02 16:28:15 +00:00
0b25072c4e Use vcm::VideoReceiver on the receive side.
BUG=
R=perkj@webrtc.org

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

Cr-Commit-Position: refs/heads/master@{#12473}
2016-04-22 16:23:26 +00:00
cd5c25cb80 Use vcm::VideoSender in ViEEncoder.
ViEEncoder doesn't need a full VideoCodingModule since it only uses the
sender side either way.

BUG=webrtc:3608,webrtc:5687
R=perkj@webrtc.org

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

Cr-Commit-Position: refs/heads/master@{#12456}
2016-04-21 14:48:18 +00:00
02b3d275a0 Reland of Deprecate VCMPacketizationCallback::SendData and use EncodedImageCallback instead. (patchset #1 id:1 of https://codereview.webrtc.org/1903193002/ )
Reason for revert:
A fix is being prepared downstream so this can now go in.

Original issue's description:
> Revert of Deprecate VCMPacketizationCallback::SendData and use EncodedImageCallback instead. (patchset #5 id:80001 of https://codereview.webrtc.org/1897233002/ )
>
> Reason for revert:
> API changes broke downstream.
>
> Original issue's description:
> > Deprecate VCMPacketizationCallback::SendData and use EncodedImageCallback instead.
> > EncodedImageCallback is used by all encoder implementations and seems to be what we should try to use in the transport.
> > EncodedImageCallback can of course be cleaned up in the future.
> >
> > This moves creation of RTPVideoHeader from the GenericEncoder to the PayLoadRouter.
> >
> > BUG=webrtc::5687
> >
> > Committed: https://crrev.com/f5d55aaecdc39e9cc66eb6e87614f04afe28f6eb
> > Cr-Commit-Position: refs/heads/master@{#12436}
>
> TBR=stefan@webrtc.org,pbos@webrtc.org,perkj@webrtc.org
> # Skipping CQ checks because original CL landed less than 1 days ago.
> NOPRESUBMIT=true
> NOTREECHECKS=true
> NOTRY=true
> BUG=webrtc:5687
>
> Committed: https://crrev.com/a261e6136655af33f283eda8e60a6dd93dd746a4
> Cr-Commit-Position: refs/heads/master@{#12441}

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

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

Cr-Commit-Position: refs/heads/master@{#12442}
2016-04-20 12:06:01 +00:00
a261e61366 Revert of Deprecate VCMPacketizationCallback::SendData and use EncodedImageCallback instead. (patchset #5 id:80001 of https://codereview.webrtc.org/1897233002/ )
Reason for revert:
API changes broke downstream.

Original issue's description:
> Deprecate VCMPacketizationCallback::SendData and use EncodedImageCallback instead.
> EncodedImageCallback is used by all encoder implementations and seems to be what we should try to use in the transport.
> EncodedImageCallback can of course be cleaned up in the future.
>
> This moves creation of RTPVideoHeader from the GenericEncoder to the PayLoadRouter.
>
> BUG=webrtc::5687
>
> Committed: https://crrev.com/f5d55aaecdc39e9cc66eb6e87614f04afe28f6eb
> Cr-Commit-Position: refs/heads/master@{#12436}

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

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

Cr-Commit-Position: refs/heads/master@{#12441}
2016-04-20 11:13:30 +00:00
f5d55aaecd Deprecate VCMPacketizationCallback::SendData and use EncodedImageCallback instead.
EncodedImageCallback is used by all encoder implementations and seems to be what we should try to use in the transport.
EncodedImageCallback can of course be cleaned up in the future.

This moves creation of RTPVideoHeader from the GenericEncoder to the PayLoadRouter.

BUG=webrtc::5687

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

Cr-Commit-Position: refs/heads/master@{#12436}
2016-04-20 08:17:11 +00:00
a96b60b3a6 Move frame_callback.h to common_video/include.
BUG=webrtc:4243
R=kjellander@webrtc.org, tommi@webrtc.org

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

Cr-Commit-Position: refs/heads/master@{#12419}
2016-04-19 04:12:57 +00:00
3911c26bc0 Add support for writing raw encoder output to .ivf files.
Also refactor GenericEncoder to use these file writers, and remove use
of preprocessor to enable file writing.

BUG=

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

Cr-Commit-Position: refs/heads/master@{#12372}
2016-04-15 08:24:21 +00:00
98bb6640d2 Added log messages for some important call setup events:
- First audio RTP packet sent / received
 - First RTP packet of the first video frame sent / received
 - Last RTP packet of the first video frame sent / received
These timestamps should make it easier to measure how fast the call
becomes established from the user's perspective.

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

Cr-Commit-Position: refs/heads/master@{#12287}
2016-04-07 22:36:49 +00:00
83f831a919 Experiment for the nack module.
Testing the nack module by implementing it into the current jitter buffer
under the experiment WebRTC-NewVideoJitterBuffer.

BUG=webrtc:5514

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

Cr-Commit-Position: refs/heads/master@{#11969}
2016-03-12 11:30:31 +00:00
3f55dea259 Replace scoped_ptr with unique_ptr in webrtc/modules/video_coding/
BUG=webrtc:5520

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

Cr-Commit-Position: refs/heads/master@{#11814}
2016-02-29 13:52:06 +00:00
a26ac925f7 Reland of move ignored return code from modules. (patchset #1 id:1 of https://codereview.webrtc.org/1736663004/ )
Reason for revert:
Revert breaks other uses, a fix will be rolled into Chromium instead.

Original issue's description:
> Revert of Remove ignored return code from modules. (patchset #3 id:40001 of https://codereview.webrtc.org/1703833002/ )
>
> Reason for revert:
> Breaks Chromium.
>
> Original issue's description:
> > Remove ignored return code from modules.
> >
> > ModuleProcessImpl doesn't act on return codes and having them around is
> > confusing (it's unclear what an error return code here would do even).
> >
> > BUG=
> > R=tommi@webrtc.org
> >
> > Committed: f14c47a58c
>
> TBR=tommi@webrtc.org,pbos@webrtc.org
> # Skipping CQ checks because original CL landed less than 1 days ago.
> NOPRESUBMIT=true
> NOTREECHECKS=true
> NOTRY=true
> BUG=
>
> Committed: https://crrev.com/da33a8a2a22f6d19ba2a8cce963beafbdbaa8fd8
> Cr-Commit-Position: refs/heads/master@{#11761}

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

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

Cr-Commit-Position: refs/heads/master@{#11762}
2016-02-25 12:50:09 +00:00
da33a8a2a2 Revert of Remove ignored return code from modules. (patchset #3 id:40001 of https://codereview.webrtc.org/1703833002/ )
Reason for revert:
Breaks Chromium.

Original issue's description:
> Remove ignored return code from modules.
>
> ModuleProcessImpl doesn't act on return codes and having them around is
> confusing (it's unclear what an error return code here would do even).
>
> BUG=
> R=tommi@webrtc.org
>
> Committed: f14c47a58c

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

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

Cr-Commit-Position: refs/heads/master@{#11761}
2016-02-25 12:34:12 +00:00
f14c47a58c Remove ignored return code from modules.
ModuleProcessImpl doesn't act on return codes and having them around is
confusing (it's unclear what an error return code here would do even).

BUG=
R=tommi@webrtc.org

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

Cr-Commit-Position: refs/heads/master@{#11747}
2016-02-24 15:51:23 +00:00
e449915455 Measure encoding time on encode callbacks.
Permits measuring encoding time even when performed on another thread,
typically for hardware encoding, instead of assuming that encoding is
blocking the calling thread.

Permitted encoding time is increased for hardware encoders since they
can be timed to keep 30fps, for instance, without indicating overload.

Merges EncodingTimeObserver into EncodedFrameObserver to have one post-encode
callback.

BUG=webrtc:5042, webrtc:5132
R=asapersson@webrtc.org, mflodman@webrtc.org

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

Cr-Commit-Position: refs/heads/master@{#11499}
2016-02-05 10:13:41 +00:00
ed3277bf14 Deprecate VideoDecoder::Reset() and remove calls.
Removes calls to decoder reset and instead drops delta frames and
requests keyframes until one arrives.

BUG=webrtc:5475
R=stefan@webrtc.org
TBR=mflodman@webrtc.org

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

Cr-Commit-Position: refs/heads/master@{#11460}
2016-02-02 14:40:13 +00:00
5ad935cb56 Remove mutable from rtc::CriticalSection members.
rtc::CriticalSection is now lockable from const methods and no longer
need to remain mutable.

BUG=
R=tommi@webrtc.org

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

Cr-Commit-Position: refs/heads/master@{#11367}
2016-01-25 11:52:53 +00:00
233bfd2da4 Move keyframe requests outside encoder mutex.
Enables faster keyframe requests since they are no longer blocked by
calls to the encoder.

BUG=webrtc:5410
R=stefan@webrtc.org

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

Cr-Commit-Position: refs/heads/master@{#11294}
2016-01-18 19:23:51 +00:00
7776e782d6 Remove unused methods in VideoCodingModule.
Also voids ::Codec which always passed.

BUG=
R=stefan@webrtc.org

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

Cr-Commit-Position: refs/heads/master@{#11167}
2016-01-07 14:42:58 +00:00