niklase@google.com | 470e71d | 2011-07-07 08:21:25 +0000 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (c) 2011 The WebRTC project authors. All Rights Reserved. |
| 3 | * |
| 4 | * Use of this source code is governed by a BSD-style license |
| 5 | * that can be found in the LICENSE file in the root of the source |
| 6 | * tree. An additional intellectual property rights grant can be found |
| 7 | * in the file PATENTS. All contributing project authors may |
| 8 | * be found in the AUTHORS file in the root of the source tree. |
| 9 | */ |
| 10 | |
Mirko Bonadei | 92ea95e | 2017-09-15 06:47:31 +0200 | [diff] [blame] | 11 | #ifndef MODULES_VIDEO_CODING_PACKET_H_ |
| 12 | #define MODULES_VIDEO_CODING_PACKET_H_ |
niklase@google.com | 470e71d | 2011-07-07 08:21:25 +0000 | [diff] [blame] | 13 | |
Mirko Bonadei | 92ea95e | 2017-09-15 06:47:31 +0200 | [diff] [blame] | 14 | #include "modules/include/module_common_types.h" |
niklase@google.com | 470e71d | 2011-07-07 08:21:25 +0000 | [diff] [blame] | 15 | |
pbos@webrtc.org | 3004c79 | 2013-05-07 12:36:21 +0000 | [diff] [blame] | 16 | namespace webrtc { |
niklase@google.com | 470e71d | 2011-07-07 08:21:25 +0000 | [diff] [blame] | 17 | |
pbos@webrtc.org | 3004c79 | 2013-05-07 12:36:21 +0000 | [diff] [blame] | 18 | class VCMPacket { |
philipel | 9d3ab61 | 2015-12-21 04:12:39 -0800 | [diff] [blame] | 19 | public: |
| 20 | VCMPacket(); |
| 21 | VCMPacket(const uint8_t* ptr, |
| 22 | const size_t size, |
| 23 | const WebRtcRTPHeader& rtpHeader); |
niklase@google.com | 470e71d | 2011-07-07 08:21:25 +0000 | [diff] [blame] | 24 | |
philipel | 9d3ab61 | 2015-12-21 04:12:39 -0800 | [diff] [blame] | 25 | uint8_t payloadType; |
| 26 | uint32_t timestamp; |
| 27 | // NTP time of the capture time in local timebase in milliseconds. |
| 28 | int64_t ntp_time_ms_; |
| 29 | uint16_t seqNum; |
| 30 | const uint8_t* dataPtr; |
| 31 | size_t sizeBytes; |
| 32 | bool markerBit; |
philipel | 5ceaaae | 2016-05-24 10:20:47 +0200 | [diff] [blame] | 33 | int timesNacked; |
niklase@google.com | 470e71d | 2011-07-07 08:21:25 +0000 | [diff] [blame] | 34 | |
philipel | 9d3ab61 | 2015-12-21 04:12:39 -0800 | [diff] [blame] | 35 | FrameType frameType; |
| 36 | VideoCodecType codec; |
niklase@google.com | 470e71d | 2011-07-07 08:21:25 +0000 | [diff] [blame] | 37 | |
danilchap | b34f6a8 | 2017-05-23 11:06:56 -0700 | [diff] [blame] | 38 | bool is_first_packet_in_frame; |
philipel | ef615ea | 2018-09-13 11:07:48 +0200 | [diff] [blame] | 39 | bool is_last_packet_in_frame; |
philipel | 9d3ab61 | 2015-12-21 04:12:39 -0800 | [diff] [blame] | 40 | VCMNaluCompleteness completeNALU; // Default is kNaluIncomplete. |
| 41 | bool insertStartCode; // True if a start code should be inserted before this |
| 42 | // packet. |
| 43 | int width; |
| 44 | int height; |
isheriff | 6b4b5f3 | 2016-06-08 00:24:21 -0700 | [diff] [blame] | 45 | RTPVideoHeader video_header; |
niklase@google.com | 470e71d | 2011-07-07 08:21:25 +0000 | [diff] [blame] | 46 | |
ilnik | 04f4d12 | 2017-06-19 07:18:55 -0700 | [diff] [blame] | 47 | int64_t receive_time_ms; |
niklase@google.com | 470e71d | 2011-07-07 08:21:25 +0000 | [diff] [blame] | 48 | }; |
| 49 | |
pbos@webrtc.org | d900e8b | 2013-07-03 15:12:26 +0000 | [diff] [blame] | 50 | } // namespace webrtc |
Mirko Bonadei | 92ea95e | 2017-09-15 06:47:31 +0200 | [diff] [blame] | 51 | #endif // MODULES_VIDEO_CODING_PACKET_H_ |