This change removes RTCP Feedback loop if we are using datagram transport by removing transport sequence numbers from RTP packets and recreating RTCP Feedback from Datagram ACKs and Timestamps. - For outgoing RTP packets, remove transport sequence number and store it with datagram_id. Note that removing transport sequence numbers does not only save 4-8 bytes per packet, but also prevents generation of feedback packets on the receiver side. - When datagram ACKs, we re-created RTCP feedback with timestamp. - Replacing previous assumption that datagram_id was the same as packet_id by storing incremental counter of datagram ids (I noticed some packets come without packet_id, which is a bit strange, but easy to support and it's also good not to rely on packet_ids being unique across multiple ssrcs). Bug: webrtc:9719 Change-Id: Iecfe938ecea1a74e7c9e1484f0e985d72643d4a1 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/145269 Commit-Queue: Anton Sukhanov <sukhanov@webrtc.org> Reviewed-by: Steve Anton <steveanton@webrtc.org> Reviewed-by: Bjorn Mellem <mellem@webrtc.org> Cr-Commit-Position: refs/heads/master@{#28542}
How to write code in the api/ directory
Mostly, just follow the regular style guide, but:
- Note that
api/code is not exempt from the “.hand.ccfiles come in pairs” rule, so if you declare something inapi/path/to/foo.h, it should be defined inapi/path/to/foo.cc. - Headers in
api/should, if possible, not#includeheaders outsideapi/. It’s not always possible to avoid this, but be aware that it adds to a small mountain of technical debt that we’re trying to shrink. .ccfiles inapi/, on the other hand, are free to#includeheaders outsideapi/.
That is, the preferred way for api/ code to access non-api/ code is to call
it from a .cc file, so that users of our API headers won’t transitively
#include non-public headers.
For headers in api/ that need to refer to non-public types, forward
declarations are often a lesser evil than including non-public header files. The
usual rules still apply, though.
.cc files in api/ should preferably be kept reasonably small. If a
substantial implementation is needed, consider putting it with our non-public
code, and just call it from the api/ .cc file.