In https://codereview.webrtc.org/2034923003 it was discovered
that a test binary rtc_sdk_peerconnection_objc_tests was
a dependency to rtc_unittests. Unfortunately gtest doesn't
include dependent executables into the same test executable;
only libraries (so theses tests weren't run).
This CL incorporates those tests into rtc_unittests and
does the same changes to the GN build.
BUG=webrtc:5949
TESTED=Built and ran rtc_unittests locally on Mac.
NOTRY=True
Review-Url: https://codereview.webrtc.org/2041743003
Cr-Commit-Position: refs/heads/master@{#13060}
This CL adds support for an extension on RTP frames to allow the sender
to specify the minimum and maximum playout delay limits.
The receiver makes a best-effort attempt to keep the capture-to-render delay
within this range. This allows different types of application to specify
different end-to-end delay goals. For example gaming can support rendering
of frames as soon as received on receiver to minimize delay. A movie playback
application can specify a minimum playout delay to allow fixed buffering
in presence of network jitter.
There are no tests at this time and most of testing is done with chromium
webrtc prototype.
On chromoting performance tests, this extension helps bring down end-to-end
delay by about 150 ms on small frames.
BUG=webrtc:5895
Review-Url: https://codereview.webrtc.org/2007743003
Cr-Commit-Position: refs/heads/master@{#13059}
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}
The VUI part an SPS may specify max_num_reorder_frames and
max_dec_frame_buffering. These may cause a decoder to buffer a number
of frame prior allowing decode, leading to delays, even if no frames
using such references (ie B-frames) are sent.
Because of this we update any SPS block emitted by the encoder.
Also, a bunch of refactoring of H264-related code to reduce code
duplication.
BUG=
Review-Url: https://codereview.webrtc.org/1979443004
Cr-Commit-Position: refs/heads/master@{#13010}
This makes the GN configurations easier to read.
BUG=webrtc:5949
NOTRY=True
Review-Url: https://codereview.webrtc.org/2020343003
Cr-Commit-Position: refs/heads/master@{#13006}
Delete unused ConvertFromYV12, and dead prototypes ConvertRGB24ToARGB
ConvertNV12ToRGB565. Move Calc16ByteAlignedStride to the test file
where it is used.
BUG=
Review-Url: https://codereview.webrtc.org/2021843002
Cr-Commit-Position: refs/heads/master@{#13003}
This will hopefully resolve a crash that might occur if it thinks H264 is
supported when in fact it isn't.
BUG=chromium:615513
Review-Url: https://codereview.webrtc.org/2018273002
Cr-Commit-Position: refs/heads/master@{#12958}
Reason for revert:
Reland. It was a false alarm.
Original issue's description:
> Revert of Change ProcessThread's task type to be the one from TaskQueue. (patchset #3 id:80001 of https://codereview.webrtc.org/2016043003/ )
>
> Reason for revert:
> Downstream issues
>
> Original issue's description:
> > Change ProcessThread's task type to be the one from TaskQueue.
> > ProcessThread will eventually be replaced by TaskQueue, so this is the first little step.
> >
> > BUG=
> > R=magjed@webrtc.org
> >
> > Committed: https://crrev.com/400a276c8a0b299190ff17a81edd8780a26d63d3
> > Cr-Commit-Position: refs/heads/master@{#12952}
>
> TBR=magjed@webrtc.org
> # Not skipping CQ checks because original CL landed more than 1 days ago.
> BUG=
>
> Committed: https://crrev.com/641455176a1241dea6dda7071ba4162f41a0b5fc
> Cr-Commit-Position: refs/heads/master@{#12953}
TBR=magjed@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/2017333002
Cr-Commit-Position: refs/heads/master@{#12954}
Reason for revert:
Downstream issues
Original issue's description:
> Change ProcessThread's task type to be the one from TaskQueue.
> ProcessThread will eventually be replaced by TaskQueue, so this is the first little step.
>
> BUG=
> R=magjed@webrtc.org
>
> Committed: https://crrev.com/400a276c8a0b299190ff17a81edd8780a26d63d3
> Cr-Commit-Position: refs/heads/master@{#12952}
TBR=magjed@webrtc.org
# Not skipping CQ checks because original CL landed more than 1 days ago.
BUG=
Review-Url: https://codereview.webrtc.org/2020783003
Cr-Commit-Position: refs/heads/master@{#12953}
If deleting files fails, wait a sec and retry. This can help in case
and antivirus software or similar has locked the file, preventing it
from being deleted.
BUG=webrtc:5898
Review-Url: https://codereview.webrtc.org/2014823002
Cr-Commit-Position: refs/heads/master@{#12917}
Compile fixes for GN on iOS that finally gets our bots green.
Changes to system_wrappers:
* Updated to only use inclusive sources for maintainability
* Add a few missing GN headers.
* Cleanup GYP hack for atomic32_mac.cc
* Renamed changes sources to avoid problems with GYP/GN file
suffix rules:
- atomic32_mac.cc -> atomic32_darwin.cc
- atomic32_posix.cc -> atomic32_non_darwin_unix.cc
See https://code.google.com/p/chromium/codesearch#chromium/src/build/config/BUILDCONFIG.gn&l=325
for details on which extensions can/cannot be used.
BUG=webrtc:5586
NOTRY=True
Review-Url: https://codereview.webrtc.org/1999723002
Cr-Commit-Position: refs/heads/master@{#12897}
Previously, failure codes were ignored, which meant simulcasted codecs
couldn't e.g. trigger software fallback. This stops the simulcasted
Encode call at the first faiulre and returns that code.
Another option is to continue sending the frame to the other encoders
but still return the first failure code. It's not clear that that is any
better than just quitting as soon as a failure happens.
BUG=
Review-Url: https://codereview.webrtc.org/2008723002
Cr-Commit-Position: refs/heads/master@{#12892}
Updated tests to use the default implementation and removed the test implementation (webrtc/test/histograms.h).
BUG=
Review-Url: https://codereview.webrtc.org/1915523002
Cr-Commit-Position: refs/heads/master@{#12829}
Reason for revert:
Should work after cl https://codereview.webrtc.org/1985693002/ is landed, which initializes the frames used by FakeWebRtcVideoCaptureModule. So intend to reland after that, with no changes.
Original issue's description:
> Revert of Delete webrtc::VideoFrame methods buffer and stride. (patchset #2 id:290001 of https://codereview.webrtc.org/1963413004/ )
>
> Reason for revert:
> Speculative revert to see if failures on the DrMemory bot are related to this cl. See e.g. here:
> https://build.chromium.org/p/client.webrtc/builders/Win%20DrMemory%20Full/builds/4243
>
> UNINITIALIZED READ: reading 0x04980040-0x04980060 32 byte(s) within 0x04980040-0x04980060
> # 0 CopyRow_AVX
> # 1 CopyPlane
> # 2 I420Copy
> # 3 webrtc::ExtractBuffer
> # 4 cricket::WebRtcVideoCapturer::SignalFrameCapturedOnStartThread
> # 5 cricket::WebRtcVideoCapturer::OnIncomingCapturedFrame
> # 6 FakeWebRtcVideoCaptureModule::SendFrame
> # 7 WebRtcVideoCapturerTest_TestCaptureVcm_Test::TestBody
> # 8 testing::internal::HandleSehExceptionsInMethodIfSupported<>
>
> Original issue's description:
> > Reland of Delete webrtc::VideoFrame methods buffer and stride. (patchset #1 id:1 of https://codereview.webrtc.org/1935443002/ )
> >
> > Reason for revert:
> > I plan to reland this change in a week or two, after downstream users are updated.
> >
> > Original issue's description:
> > > Revert of Delete webrtc::VideoFrame methods buffer and stride. (patchset #14 id:250001 of https://codereview.webrtc.org/1900673002/ )
> > >
> > > Reason for revert:
> > > Breaks chrome FYI bots.
> > >
> > > Original issue's description:
> > > > Delete webrtc::VideoFrame methods buffer and stride.
> > > >
> > > > To make the HasOneRef/IsMutable hack work, also had to change the
> > > > video_frame_buffer method to return a const ref to a scoped_ref_ptr,
> > > > to not imply an AddRef.
> > > >
> > > > BUG=webrtc:5682
> > >
> > > TBR=perkj@webrtc.org,magjed@webrtc.org,pbos@webrtc.org,pthatcher@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:5682
> > >
> > > Committed: https://crrev.com/5b3c443d301f2c2f18dac5b02652c08b91ea3828
> > > Cr-Commit-Position: refs/heads/master@{#12558}
> >
> > TBR=perkj@webrtc.org,magjed@webrtc.org,pbos@webrtc.org,pthatcher@webrtc.org,stefan@webrtc.org
> > # Not skipping CQ checks because original CL landed more than 1 days ago.
> > BUG=webrtc:5682
> >
> > Committed: https://crrev.com/d0dc66e0ea30c8614001e425a4ae0aa7dd56c2a7
> > Cr-Commit-Position: refs/heads/master@{#12721}
>
> TBR=perkj@webrtc.org,magjed@webrtc.org,pbos@webrtc.org,pthatcher@webrtc.org,stefan@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/d49c30cd2fe442f2b5b4ecec8d5cbaa430464725
> Cr-Commit-Position: refs/heads/master@{#12745}
TBR=perkj@webrtc.org,magjed@webrtc.org,pbos@webrtc.org,pthatcher@webrtc.org,stefan@webrtc.org,tommi@webrtc.org
# Not skipping CQ checks because original CL landed more than 1 days ago.
BUG=webrtc:5682
Review-Url: https://codereview.webrtc.org/1979193003
Cr-Commit-Position: refs/heads/master@{#12773}
Reason for revert:
Speculative revert to see if failures on the DrMemory bot are related to this cl. See e.g. here:
https://build.chromium.org/p/client.webrtc/builders/Win%20DrMemory%20Full/builds/4243
UNINITIALIZED READ: reading 0x04980040-0x04980060 32 byte(s) within 0x04980040-0x04980060
# 0 CopyRow_AVX
# 1 CopyPlane
# 2 I420Copy
# 3 webrtc::ExtractBuffer
# 4 cricket::WebRtcVideoCapturer::SignalFrameCapturedOnStartThread
# 5 cricket::WebRtcVideoCapturer::OnIncomingCapturedFrame
# 6 FakeWebRtcVideoCaptureModule::SendFrame
# 7 WebRtcVideoCapturerTest_TestCaptureVcm_Test::TestBody
# 8 testing::internal::HandleSehExceptionsInMethodIfSupported<>
Original issue's description:
> Reland of Delete webrtc::VideoFrame methods buffer and stride. (patchset #1 id:1 of https://codereview.webrtc.org/1935443002/ )
>
> Reason for revert:
> I plan to reland this change in a week or two, after downstream users are updated.
>
> Original issue's description:
> > Revert of Delete webrtc::VideoFrame methods buffer and stride. (patchset #14 id:250001 of https://codereview.webrtc.org/1900673002/ )
> >
> > Reason for revert:
> > Breaks chrome FYI bots.
> >
> > Original issue's description:
> > > Delete webrtc::VideoFrame methods buffer and stride.
> > >
> > > To make the HasOneRef/IsMutable hack work, also had to change the
> > > video_frame_buffer method to return a const ref to a scoped_ref_ptr,
> > > to not imply an AddRef.
> > >
> > > BUG=webrtc:5682
> >
> > TBR=perkj@webrtc.org,magjed@webrtc.org,pbos@webrtc.org,pthatcher@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:5682
> >
> > Committed: https://crrev.com/5b3c443d301f2c2f18dac5b02652c08b91ea3828
> > Cr-Commit-Position: refs/heads/master@{#12558}
>
> TBR=perkj@webrtc.org,magjed@webrtc.org,pbos@webrtc.org,pthatcher@webrtc.org,stefan@webrtc.org
> # Not skipping CQ checks because original CL landed more than 1 days ago.
> BUG=webrtc:5682
>
> Committed: https://crrev.com/d0dc66e0ea30c8614001e425a4ae0aa7dd56c2a7
> Cr-Commit-Position: refs/heads/master@{#12721}
TBR=perkj@webrtc.org,magjed@webrtc.org,pbos@webrtc.org,pthatcher@webrtc.org,stefan@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
Review-Url: https://codereview.webrtc.org/1983583002
Cr-Commit-Position: refs/heads/master@{#12745}
Remove ViEEncoder::SetNetworkStatus.
Original cl description:
This cl removed ViEEncoder::SetNetworkStatus. Instead the PacedSender will report that frames can not be sent when the network is down and the BitrateController will report an estimated available bandwidth of 0 bps.
Patchset #1 is a pure reland.
Patchset #2 change the bitrate allocator to always return an initial bitrate >0 regardless of the estimates. The observer will be notified though if the network is down.
BUG=webrtc:5687
Review-Url: https://codereview.webrtc.org/1972183004
Cr-Commit-Position: refs/heads/master@{#12743}
Wires up existing libvpx_build_vp9==0 GYP flag into WebRTC and makes VP9
optional. Change is GYP only for now since libvpx's GN files build VP9
unconditionally.
BUG=webrtc:5884
R=kjellander@webrtc.org
Review URL: https://codereview.webrtc.org/1970343002 .
Cr-Commit-Position: refs/heads/master@{#12741}
Reason for revert:
I plan to reland this change in a week or two, after downstream users are updated.
Original issue's description:
> Revert of Delete webrtc::VideoFrame methods buffer and stride. (patchset #14 id:250001 of https://codereview.webrtc.org/1900673002/ )
>
> Reason for revert:
> Breaks chrome FYI bots.
>
> Original issue's description:
> > Delete webrtc::VideoFrame methods buffer and stride.
> >
> > To make the HasOneRef/IsMutable hack work, also had to change the
> > video_frame_buffer method to return a const ref to a scoped_ref_ptr,
> > to not imply an AddRef.
> >
> > BUG=webrtc:5682
>
> TBR=perkj@webrtc.org,magjed@webrtc.org,pbos@webrtc.org,pthatcher@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:5682
>
> Committed: https://crrev.com/5b3c443d301f2c2f18dac5b02652c08b91ea3828
> Cr-Commit-Position: refs/heads/master@{#12558}
TBR=perkj@webrtc.org,magjed@webrtc.org,pbos@webrtc.org,pthatcher@webrtc.org,stefan@webrtc.org
# Not skipping CQ checks because original CL landed more than 1 days ago.
BUG=webrtc:5682
Review-Url: https://codereview.webrtc.org/1963413004
Cr-Commit-Position: refs/heads/master@{#12721}
OnReceivedPacket now return the number of times the packet has been nacked. Also some minor refactoring.
BUG=webrtc:5514
R=stefan@webrtc.org
Review URL: https://codereview.webrtc.org/1972123002 .
Cr-Commit-Position: refs/heads/master@{#12717}
Fixes bug where QualityScaler would be stuck "way below" QVGA (due to
downscale_shift_) even though it would never scale below QVGA. Also
fixes issue where samples would be cleared when either staying at max
resolution or going below QVGA even though no action happened.
BUG=
R=glaznev@webrtc.org
Review URL: https://codereview.webrtc.org/1971693003 .
Cr-Commit-Position: refs/heads/master@{#12691}
Reason for revert:
Breaks user code. Said code needs to stop using scoped_ptr!
Original issue's description:
> Remove webrtc/base/scoped_ptr.h
>
> BUG=webrtc:5520
>
> NOTRY=True
>
> Committed: https://crrev.com/65fc62e9dd8a8716db625aaef76ab92f542ecc5a
> Cr-Commit-Position: refs/heads/master@{#12684}
TBR=tommi@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=webrtc:5520
Review-Url: https://codereview.webrtc.org/1965063003
Cr-Commit-Position: refs/heads/master@{#12686}
Reason for revert:
Not perf-regression culprit.
Original issue's description:
> Revert of Rename OpenH264 frame-type conversion function. (patchset #2 id:20001 of https://codereview.webrtc.org/1943193003/ )
>
> Reason for revert:
> Speculative revert for perf regression (though unlikely).
>
> Original issue's description:
> > Rename OpenH264 frame-type conversion function.
> >
> > Also removing default case, so if another frame is added to
> > EVideoFrameType we have to handle it.
> >
> > This will now NOTREACHED on videoFrameTypeInvalid, but
> > videoFrameTypeInvalid shouldn't happen if encoding succeeds, so it
> > should be fine or we should become aware of it.
> >
> > BUG=
> > R=hbos@webrtc.org
> >
> > Committed: https://crrev.com/39a36705ab734914d500b8a0f214ea630d82ab70
> > Cr-Commit-Position: refs/heads/master@{#12636}
>
> TBR=hbos@webrtc.org
> # Not skipping CQ checks because original CL landed more than 1 days ago.
> BUG=chromium:610347
>
> Committed: https://crrev.com/1abf937cecea56ee02ac4a08980ffea9e7ed1054
> Cr-Commit-Position: refs/heads/master@{#12677}
TBR=hbos@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=chromium:610347
Review-Url: https://codereview.webrtc.org/1970513004
Cr-Commit-Position: refs/heads/master@{#12679}
Reason for revert:
Speculative revert for perf regression (though unlikely).
Original issue's description:
> Rename OpenH264 frame-type conversion function.
>
> Also removing default case, so if another frame is added to
> EVideoFrameType we have to handle it.
>
> This will now NOTREACHED on videoFrameTypeInvalid, but
> videoFrameTypeInvalid shouldn't happen if encoding succeeds, so it
> should be fine or we should become aware of it.
>
> BUG=
> R=hbos@webrtc.org
>
> Committed: https://crrev.com/39a36705ab734914d500b8a0f214ea630d82ab70
> Cr-Commit-Position: refs/heads/master@{#12636}
TBR=hbos@webrtc.org
# Not skipping CQ checks because original CL landed more than 1 days ago.
BUG=chromium:610347
Review URL: https://codereview.webrtc.org/1964913002 .
Cr-Commit-Position: refs/heads/master@{#12677}
The logging code was using the wrong constants for the
codec type, resulting in the type always being "unknown".
Tested: modules_unittests --gtest_filter='IvfFile*' -logs
BUG=
Review-Url: https://codereview.webrtc.org/1955273002
Cr-Commit-Position: refs/heads/master@{#12668}
Also removing default case, so if another frame is added to
EVideoFrameType we have to handle it.
This will now NOTREACHED on videoFrameTypeInvalid, but
videoFrameTypeInvalid shouldn't happen if encoding succeeds, so it
should be fine or we should become aware of it.
BUG=
R=hbos@webrtc.org
Review-Url: https://codereview.webrtc.org/1943193003
Cr-Commit-Position: refs/heads/master@{#12636}
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}
Reason for revert:
Previous mode aligns with other encoders, and RC_TIMESTAMP_MODE might have issues with no frames for several seconds.
Original issue's description:
> Use RC_TIMESTAMP_MODE for OpenH264.
>
> Performs rate control based on timestamp deltas instead of announced
> frame rate.
>
> BUG=webrtc:5855
> R=hbos@webrtc.org
>
> Committed: https://crrev.com/c4deee49a3ec42b7fe83c82f750539b36aae1d3f
> Cr-Commit-Position: refs/heads/master@{#12611}
TBR=hbos@webrtc.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=webrtc:5855
Review-Url: https://codereview.webrtc.org/1950973002
Cr-Commit-Position: refs/heads/master@{#12629}