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}
Compact NTP representation was designed exactly for that purpose: calculate RTT. No need to map to ms before doing arithmetic on this values.
Because of this change there is no need to keep mapping between compact ntp presentation and milliseconds in the RTCPSender.
BUG=webrtc:5565
R=stefan@webrtc.org
Review URL: https://codereview.webrtc.org/1491843004 .
Cr-Commit-Position: refs/heads/master@{#11710}
Also move some stats reporting from vie_channel to send stats proxy
BUG=
Review URL: https://codereview.webrtc.org/1669623004
Cr-Commit-Position: refs/heads/master@{#11688}
Prevents allocating sequence numbers for packets that go out on the
network even though sending media is disabled.
This race caused a replay of sequence numbers when GetRtpState() on a
stopped stream would not return the last sequence number sent, since the
pacer thread could request and send padding on a later sequence number
before the modules are disconnected from the pacer.
BUG=webrtc:5543
R=stefan@webrtc.org
TEST=Repeating EndToEndTest.RestartingSendStreamPreservesRtpState 1000 times under TSan.
Review URL: https://codereview.webrtc.org/1715703002 .
Cr-Commit-Position: refs/heads/master@{#11685}
There were two different structures named RtpPacket in webrtc namespace:
RtpPacket defined in fec_test_helper renamed to test::RawRtpPacket
RtpPacket defined in rtp_sender_video and producer_fec removed as unused
BUG=webrtc:5261
R=sprang@google.com, stefan@webrtc.org
Review URL: https://codereview.webrtc.org/1710103004 .
Cr-Commit-Position: refs/heads/master@{#11682}
When composing a RTCP packet, if there is a BYE
to be appended, preserve it and append it at the
end after all other packet types are added.
BUG=webrtc:5498
NOTRY=true
Review URL: https://codereview.webrtc.org/1674963004
Cr-Commit-Position: refs/heads/master@{#11672}
rtcp::RawPacket is rtc::Buffer, it had no extra functionality.
rtc::Buffer is a movable class - no point to wrap it into rtc::scoped_ptr
change is large, but straightforward:
rtc::scoped_ptr<rtcp::RawPacket> replaced with rtc::Buffer
->Buffer() replaced with .data()
->Length() replaced with .size()
BUG=webrtc:5260
Review URL: https://codereview.webrtc.org/1696203002
Cr-Commit-Position: refs/heads/master@{#11649}
TMMBN was capped by configured max bitrate for no apparent reason.
Removing this to not require payload-type reconfiguration on new
video-codec settings. Actual removal of payload-type reconfiguration
will happen in a pending CL.
BUG=webrtc:5494
R=stefan@webrtc.org
Review URL: https://codereview.webrtc.org/1702043002 .
Cr-Commit-Position: refs/heads/master@{#11639}
Since the address of the dereference is taken this inputs a garbage
almost-null pointer into RtpPacketizer. Not likely that a load/store is
performed on the address, but UBSan fires and it's a source of potential
future errors.
BUG=webrtc:5124, webrtc:5490
R=stefan@webrtc.org
Review URL: https://codereview.webrtc.org/1677003002 .
Cr-Commit-Position: refs/heads/master@{#11528}
Added accessor and Parse function
removed dependencies on structures from rtcp_utility.h (except RtcpCommonHeader)
removed limitation of 50 items per TMMBN.
BUG=webrtc:5260
R=åsapersson
Review URL: https://codereview.webrtc.org/1670973002
Cr-Commit-Position: refs/heads/master@{#11524}
Added accessor and Parse function
removed dependencies on structures from rtcp_utility.h (except RtcpCommonHeader)
BUG=webrtc:5260
R=åsapersson
Review URL: https://codereview.webrtc.org/1675583002
Cr-Commit-Position: refs/heads/master@{#11502}
This is needed because the target is defined in webrtc/common.gyp
and its current location crosses package boundaries when generating
projects for some build systems.
NOTRY=True
Review URL: https://codereview.webrtc.org/1665603003
Cr-Commit-Position: refs/heads/master@{#11496}
std::vector<rtcp::TmmbItem> will replace TMMBRSet class for storage, processing and preparing TMBBR/TMMBN
(i.e. this TmmbItem replaces Timber structure introduced in https://codereview.webrtc.org/1474693002 )
Previous structures store bitrate in kbps. TmmbItem use bps removing need to regularly divide and multiply by 1000.
BUG=webrtc:5260
R=åsapersson
Review URL: https://codereview.webrtc.org/1576223003
Cr-Commit-Position: refs/heads/master@{#11491}
Adds negotiation of rtx codecs for red and vp9. To keep backwards
compatibility with older Chrome versions, this change includes two
hacks:
1. Red packets will be retransmitted over the rtx codec associated with
vp8 if no rtx codec is associated with red. This is how Chrome does
it today and ensures that we still can send red over rtx to older
versions.
2. If rtx packets associated with the media codec (vp8/vp9 etc) are
received and red has been negotiated, we will assume that the sender
incorrectly has packetized red inside the rtx header associated with
media. We will therefore restore it with the red payload type
instead, which ensures that we can still receive rtx associated with
red from old versions.
Offering multiple rtx codecs to older versions should not be a problem
since old versions themselves only try to negotiate rtx for vp8.
R=pbos@webrtc.orgTBR=mflodman@webrtc.org
BUG=webrtc:4024
TEST=Verified by running apprtc and emulating packet loss between Chrome with and without the patch.
Review URL: https://codereview.webrtc.org/1649493004 .
Cr-Commit-Position: refs/heads/master@{#11472}
It's generated by some encoders between SPS/PPS and an IDR frame, so we should treat it like sps/pps.
BUG=
Review URL: https://codereview.webrtc.org/1664733002
Cr-Commit-Position: refs/heads/master@{#11470}
* SSRCDatabase doesn't need to be a global instance, so I've changed it to be a "regular" class (i.e. construct via ctor, not maybe via GetSSRCDatabase( + release via ReturnSSRCDatabase())). If we ever have parallel tests running in the same process, they won't have the problem of using the same ssrc database.
* Made RtpSender a more const. Also added some todos for myself and holmer to look into clarifying the threading model.
* Switched from CriticalSectionWrapper to rtc::CriticalSection
* Changed the random seeding to use TickTime::Now().Ticks() since TimeInMicroseconds() could return 0 when the process was starting. This is what TimeInMicroseconds() does anyway but now we don't need to access a global clock object.
BUG=webrtc:3062
Review URL: https://codereview.webrtc.org/1623543002
Cr-Commit-Position: refs/heads/master@{#11462}
SetRtpState function was updating only rtp_sender start timestamp.
Now it updates both rtp_sender and rtcp_sender start timestamps.
BUG=webrtc:5433
R=stefan@webrtc.org
Review URL: https://codereview.webrtc.org/1628323003 .
Cr-Commit-Position: refs/heads/master@{#11393}
This structure is used outside Dlrr creating/parsing.
but RTCPReceiveTimeInfo structure doesn't follow naming style.
rtcp::ReceiveTimeInfo added to replace both Dlrr::SubBlock (when creating/parsing packets)
and RTCPReceiveTimeInfo (for other uses).
this CL is a split of https://codereview.webrtc.org/1557593002/
BUG=webrtc:5260
R=asapersson@webrtc.org, åsapersson
Review URL: https://codereview.webrtc.org/1631683002 .
Cr-Commit-Position: refs/heads/master@{#11380}
The specializations for 4-byte reading did not return correct
values. This has to do with the order of casting and shifting. Also
adding a test to expose the bug (and verify the other byte sizes).
Review URL: https://codereview.webrtc.org/1615653011
Cr-Commit-Position: refs/heads/master@{#11364}
Adds logging to RTPSender and RTCPSender, pushing an event log pointer from Channel through ModuleRtpRtcpImpl to the Sender objects.
BUG=webrtc:4741
Review URL: https://codereview.webrtc.org/1571283002
Cr-Commit-Position: refs/heads/master@{#11336}
The current expectation for InsertPacket(...) uses WillRepeatedly, which accepts if the function is called zero or more times. This CL changes this to either a fixed number of calls, or at least a positive number of calls.
Review URL: https://codereview.webrtc.org/1585783003
Cr-Commit-Position: refs/heads/master@{#11256}
Class renamed to indicated use of the rtcp::Empty class: it can only be used as container for other rtcp packets.
All tests that use Append function moved from rtcp_packet_unittest, even if they did not use Empty class.
This is because there is plan to make RtcpPacket class lighter by moving Append functionality to CompoundPacket class.
BUG=webrtc:5260
R=åsapersson
Review URL: https://codereview.webrtc.org/1582503002
Cr-Commit-Position: refs/heads/master@{#11234}
Removes multiple index lookups to generated_fec_packets_ speeding up
FecTest.FecTest with >2x in both Debug and Release, improving
performance but also readability.
On Debug this means that the slowest test in modules_tests now takes
~15-20 seconds instead of 50+ seconds, reducing the overall bottleneck.
BUG=webrtc:4712
R=stefan@webrtc.org
Review URL: https://codereview.webrtc.org/1552563003 .
Cr-Commit-Position: refs/heads/master@{#11166}
public function RtpHeaderParser::Parse with old signature restored as deprecated.
BUG=webrtc:5277
TBR=åsapersson
NOTRY=True
Review URL: https://codereview.webrtc.org/1550283002
Cr-Commit-Position: refs/heads/master@{#11135}
PrepareReportBlock and AddReportBlock private functions merged:
PrepareReportBlock moved report block from statistic to temporary structure
AddReportBlock copied that temporary structure into temporary map right after.
Thanks to rtcp packet classes that temporary structure is now unneccesary.
BUG=webrtc:5260
R=åsapersson
Review URL: https://codereview.webrtc.org/1538833002
Cr-Commit-Position: refs/heads/master@{#11112}
We can now use std::move instead!
This CL leaves the Pass methods in place; a follow-up CL will add deprecation annotations to them.
Review URL: https://codereview.webrtc.org/1460043002
Cr-Commit-Position: refs/heads/master@{#11064}