Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(224)

Unified Diff: webrtc/modules/rtp_rtcp/include/rtp_rtcp_defines.h

Issue 2867713003: Remove hardcoded kValueSizeBytes values from variable-length header extensions. (Closed)
Patch Set: Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: webrtc/modules/rtp_rtcp/include/rtp_rtcp_defines.h
diff --git a/webrtc/modules/rtp_rtcp/include/rtp_rtcp_defines.h b/webrtc/modules/rtp_rtcp/include/rtp_rtcp_defines.h
index 11bc9433a45709dd73255d0d0f3c64766488a613..103704cbb3493e77bda429121fc0f3168c75f3b7 100644
--- a/webrtc/modules/rtp_rtcp/include/rtp_rtcp_defines.h
+++ b/webrtc/modules/rtp_rtcp/include/rtp_rtcp_defines.h
@@ -128,6 +128,16 @@ enum RtxMode {
const size_t kRtxHeaderSize = 2;
+struct RTPExtensionSizeInfo {
danilchap 2017/05/08 16:25:06 may be RtpExtensionSize or RtpHeaderExtensionSize:
erikvarga1 2017/05/09 11:40:03 Done. I saw RTP in a few places so I thought that
danilchap 2017/05/09 12:33:48 May be hide this struct in less public header and
erikvarga1 2017/05/09 13:30:30 Done.
+ RTPExtensionType type;
+ uint8_t value_size;
+};
+
+template <typename Extension>
+constexpr RTPExtensionSizeInfo CreateExtensionSizeInfo() {
danilchap 2017/05/08 16:25:06 planning to use this function outside of the rtp_r
erikvarga1 2017/05/09 11:40:03 I don't think so. This is used solely for the RTP
danilchap 2017/05/09 12:33:48 Then do not declare it here: it seems you use it i
erikvarga1 2017/05/09 13:30:30 Done.
+ return {Extension::kId, Extension::kValueSizeBytes};
+}
+
struct RTCPSenderInfo {
uint32_t NTPseconds;
uint32_t NTPfraction;

Powered by Google App Engine
This is Rietveld 408576698