Add `AbsoluteCaptureTime` to `RtpPacketInfo`.

This change stores the optional `AbsoluteCaptureTime` header extension in `RtpPacketInfo` so that we later can consume it in `SourceTracker`.

Bug: webrtc:10739
Change-Id: I975e8863117fcda134535cd49ad71079a7ff38ec
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/148068
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Chen Xing <chxg@google.com>
Cr-Commit-Position: refs/heads/master@{#28790}
diff --git a/api/rtp_packet_info.h b/api/rtp_packet_info.h
index a9e8655..6973027 100644
--- a/api/rtp_packet_info.h
+++ b/api/rtp_packet_info.h
@@ -17,6 +17,7 @@
 
 #include "absl/types/optional.h"
 #include "api/rtp_headers.h"
+#include "rtc_base/deprecation.h"
 
 namespace webrtc {
 
@@ -33,6 +34,15 @@
                 std::vector<uint32_t> csrcs,
                 uint32_t rtp_timestamp,
                 absl::optional<uint8_t> audio_level,
+                absl::optional<AbsoluteCaptureTime> absolute_capture_time,
+                int64_t receive_time_ms);
+
+  // TODO(bugs.webrtc.org/10739): Will be removed sometime after 2019-09-19.
+  RTC_DEPRECATED
+  RtpPacketInfo(uint32_t ssrc,
+                std::vector<uint32_t> csrcs,
+                uint32_t rtp_timestamp,
+                absl::optional<uint8_t> audio_level,
                 int64_t receive_time_ms);
 
   RtpPacketInfo(const RTPHeader& rtp_header, int64_t receive_time_ms);
@@ -54,6 +64,14 @@
   absl::optional<uint8_t> audio_level() const { return audio_level_; }
   void set_audio_level(absl::optional<uint8_t> value) { audio_level_ = value; }
 
+  const absl::optional<AbsoluteCaptureTime>& absolute_capture_time() const {
+    return absolute_capture_time_;
+  }
+  void set_absolute_capture_time(
+      const absl::optional<AbsoluteCaptureTime>& value) {
+    absolute_capture_time_ = value;
+  }
+
   int64_t receive_time_ms() const { return receive_time_ms_; }
   void set_receive_time_ms(int64_t value) { receive_time_ms_ = value; }
 
@@ -68,6 +86,10 @@
   // https://tools.ietf.org/html/rfc6464#section-3
   absl::optional<uint8_t> audio_level_;
 
+  // Fields from the Absolute Capture Time header extension:
+  // http://www.webrtc.org/experiments/rtp-hdrext/abs-capture-time
+  absl::optional<AbsoluteCaptureTime> absolute_capture_time_;
+
   // Local |webrtc::Clock|-based timestamp of when the packet was received.
   int64_t receive_time_ms_;
 };