1 #ifndef __KINESIS_VIDEO_WEBRTC_CLIENT_PEERCONNECTION_RTCP__
2 #define __KINESIS_VIDEO_WEBRTC_CLIENT_PEERCONNECTION_RTCP__
19 #define TWCC_TICKS_PER_SECOND (1000000LL / 250)
20 #define MICROSECONDS_PER_SECOND 1000000LL
21 #define MILLISECONDS_PER_SECOND 1000LL
22 #define TWCC_PACKET_LOST_TIME ((UINT64) (-1LL))
23 #define TWCC_PACKET_UNITIALIZED_TIME 0
24 #define TWCC_ESTIMATOR_TIME_WINDOW (1 * HUNDREDS_OF_NANOS_IN_A_SECOND)
32 #define TWCC_FB_PACKETCHUNK_SIZE 2
33 #define IS_TWCC_RUNLEN(packetChunk) ((((packetChunk) >> 15u) & 1u) == 0)
34 #define TWCC_RUNLEN_STATUS_SYMBOL(packetChunk) (((packetChunk) >> 13u) & 3u)
35 #define TWCC_RUNLEN_GET(packetChunk) ((packetChunk) & 0x1fffu)
36 #define TWCC_IS_NOTRECEIVED(statusSymbol) ((statusSymbol) == TWCC_STATUS_SYMBOL_NOTRECEIVED)
37 #define TWCC_ISRECEIVED(statusSymbol) ((statusSymbol) == TWCC_STATUS_SYMBOL_SMALLDELTA || (statusSymbol) == TWCC_STATUS_SYMBOL_LARGEDELTA)
38 #define TWCC_RUNLEN_ISRECEIVED(packetChunk) TWCC_ISRECEIVED(TWCC_RUNLEN_STATUS_SYMBOL(packetChunk))
39 #define TWCC_STATUSVECTOR_IS_2BIT(packetChunk) (((packetChunk) >> 14u) & 1u)
40 #define TWCC_STATUSVECTOR_SSIZE(packetChunk) (TWCC_STATUSVECTOR_IS_2BIT(packetChunk) ? 2u : 1u)
41 #define TWCC_STATUSVECTOR_SMASK(packetChunk) (TWCC_STATUSVECTOR_IS_2BIT(packetChunk) ? 2u : 1u)
42 #define TWCC_STATUSVECTOR_STATUS(packetChunk, i) \
43 (((packetChunk) >> (14u - (i) * TWCC_STATUSVECTOR_SSIZE(packetChunk))) & TWCC_STATUSVECTOR_SMASK(packetChunk))
44 #define TWCC_STATUSVECTOR_COUNT(packetChunk) (TWCC_STATUSVECTOR_IS_2BIT(packetChunk) ? 7 : 14)
45 #define TWCC_PACKET_STATUS_COUNT(payload) (getUnalignedInt16BigEndian((payload) + 10))
TWCC_STATUS_SYMBOL
Definition: Rtcp.h:26
@ TWCC_STATUS_SYMBOL_LARGEDELTA
Definition: Rtcp.h:29
@ TWCC_STATUS_SYMBOL_NOTRECEIVED
Definition: Rtcp.h:27
@ TWCC_STATUS_SYMBOL_SMALLDELTA
Definition: Rtcp.h:28
STATUS updateTwccHashTable(PTwccManager, PINT64, PUINT64, PUINT64, PUINT64, PUINT64)
Definition: Rtcp.c:320
STATUS onRtcpTwccPacket(PRtcpPacket, PKvsPeerConnection)
Definition: Rtcp.c:400
STATUS onRtcpRembPacket(PRtcpPacket, PKvsPeerConnection)
Definition: Rtcp.c:492
STATUS onRtcpPacket(PKvsPeerConnection, PBYTE, UINT32)
Definition: Rtcp.c:434
STATUS onRtcpPLIPacket(PRtcpPacket, PKvsPeerConnection)
Definition: Rtcp.c:520
STATUS parseRtcpTwccPacket(PRtcpPacket, PTwccManager)
Definition: Rtcp.c:149
Definition: PeerConnection.h:72
Definition: RtcpPacket.h:72
Definition: PeerConnection.h:57