OpenCores
URL https://opencores.org/ocsvn/bluespec-h264/bluespec-h264/trunk

Subversion Repositories bluespec-h264

[/] [bluespec-h264/] [trunk/] [test/] [decoder/] [ldecod/] [inc/] [rtp.h] - Blame information for rev 100

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 14 jamey.hick
 
2
/*!
3
 *************************************************************************************
4
 * \file rtp.h
5
 *
6
 * \brief
7
 *    Prototypes for rtp.c
8
 *************************************************************************************
9
 */
10
 
11
#ifndef _RTP_H_
12
#define _RTP_H_
13
 
14
#include "nalucommon.h"
15
 
16
#define MAXRTPPAYLOADLEN  (65536 - 40)    //!< Maximum payload size of an RTP packet */
17
#define MAXRTPPACKETSIZE  (65536 - 28)    //!< Maximum size of an RTP packet incl. header */
18
#define H264PAYLOADTYPE 105               //!< RTP paylaod type fixed here for simplicity*/
19
#define H264SSRC 0x12345678               //!< SSRC, chosen to simplify debugging */
20
#define RTP_TR_TIMESTAMP_MULT 1000        //!< should be something like 27 Mhz / 29.97 Hz */
21
 
22
typedef struct
23
{
24
  unsigned int v;          //!< Version, 2 bits, MUST be 0x2
25
  unsigned int p;          //!< Padding bit, Padding MUST NOT be used
26
  unsigned int x;          //!< Extension, MUST be zero
27
  unsigned int cc;         /*!< CSRC count, normally 0 in the absence
28
                                of RTP mixers */
29
  unsigned int m;          //!< Marker bit
30
  unsigned int pt;         //!< 7 bits, Payload Type, dynamically established
31
  unsigned int seq;        /*!< RTP sequence number, incremented by one for
32
                                each sent packet */
33
  unsigned int old_seq;    //!< to detect wether packets were lost
34
  unsigned int timestamp;  //!< timestamp, 27 MHz for H.264
35
  unsigned int ssrc;       //!< Synchronization Source, chosen randomly
36
  byte *       payload;    //!< the payload including payload headers
37
  unsigned int paylen;     //!< length of payload in bytes
38
  byte *       packet;     //!< complete packet including header and payload
39
  unsigned int packlen;    //!< length of packet, typically paylen+12
40
} RTPpacket_t;
41
 
42
void DumpRTPHeader (RTPpacket_t *p);
43
 
44
int  GetRTPNALU (NALU_t *nalu);
45
void OpenRTPFile (char *fn);
46
void CloseRTPFile();
47
 
48
#endif

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.