#include "libavutil/bswap.h"
#include "libavutil/crc.h"
#include "libavutil/dict.h"
#include "libavutil/mathematics.h"
#include "libavutil/opt.h"
#include "libavcodec/mpegvideo.h"
#include "avformat.h"
#include "internal.h"
#include "mpegts.h"
#include "adts.h"
Go to the source code of this file.
Data Structures | |
struct | MpegTSSection |
struct | MpegTSService |
struct | MpegTSWrite |
struct | MpegTSWriteStream |
Macros | |
#define | PCR_TIME_BASE 27000000 |
#define | DEFAULT_PES_HEADER_FREQ 16 |
#define | DEFAULT_PES_PAYLOAD_SIZE ((DEFAULT_PES_HEADER_FREQ - 1) * 184 + 170) |
#define | SECTION_LENGTH 1020 |
#define | DEFAULT_PROVIDER_NAME "Libav" |
#define | DEFAULT_SERVICE_NAME "Service01" |
#define | SDT_RETRANS_TIME 500 |
#define | PAT_RETRANS_TIME 100 |
#define | PCR_RETRANS_TIME 20 |
Typedefs | |
typedef struct MpegTSSection | MpegTSSection |
typedef struct MpegTSService | MpegTSService |
typedef struct MpegTSWrite | MpegTSWrite |
typedef struct MpegTSWriteStream | MpegTSWriteStream |
Functions | |
static void | mpegts_write_section (MpegTSSection *s, uint8_t *buf, int len) |
static void | put16 (uint8_t **q_ptr, int val) |
static int | mpegts_write_section1 (MpegTSSection *s, int tid, int id, int version, int sec_num, int last_sec_num, uint8_t *buf, int len) |
static void | mpegts_write_pat (AVFormatContext *s) |
static void | mpegts_write_pmt (AVFormatContext *s, MpegTSService *service) |
static void | putstr8 (uint8_t **q_ptr, const char *str) |
static void | mpegts_write_sdt (AVFormatContext *s) |
static MpegTSService * | mpegts_add_service (MpegTSWrite *ts, int sid, const char *provider_name, const char *name) |
static void | section_write_packet (MpegTSSection *s, const uint8_t *packet) |
static int | mpegts_write_header (AVFormatContext *s) |
static void | retransmit_si_info (AVFormatContext *s) |
static int64_t | get_pcr (const MpegTSWrite *ts, AVIOContext *pb) |
static int | write_pcr_bits (uint8_t *buf, int64_t pcr) |
static void | mpegts_insert_null_packet (AVFormatContext *s) |
static void | mpegts_insert_pcr_only (AVFormatContext *s, AVStream *st) |
static void | write_pts (uint8_t *q, int fourbits, int64_t pts) |
static void | set_af_flag (uint8_t *pkt, int flag) |
static void | extend_af (uint8_t *pkt, int size) |
static uint8_t * | get_ts_payload_start (uint8_t *pkt) |
static void | mpegts_write_pes (AVFormatContext *s, AVStream *st, const uint8_t *payload, int payload_size, int64_t pts, int64_t dts, int key) |
static int | mpegts_write_packet (AVFormatContext *s, AVPacket *pkt) |
static int | mpegts_write_end (AVFormatContext *s) |
Variables | |
static const AVOption | options [] |
static const AVClass | mpegts_muxer_class |
AVOutputFormat | ff_mpegts_muxer |
#define DEFAULT_PES_HEADER_FREQ 16 |
Definition at line 82 of file mpegtsenc.c.
#define DEFAULT_PES_PAYLOAD_SIZE ((DEFAULT_PES_HEADER_FREQ - 1) * 184 + 170) |
Definition at line 83 of file mpegtsenc.c.
#define DEFAULT_PROVIDER_NAME "Libav" |
Definition at line 199 of file mpegtsenc.c.
Referenced by mpegts_write_header().
#define DEFAULT_SERVICE_NAME "Service01" |
Definition at line 200 of file mpegtsenc.c.
Referenced by mpegts_write_header().
#define PAT_RETRANS_TIME 100 |
Definition at line 204 of file mpegtsenc.c.
Referenced by mpegts_write_header().
#define PCR_RETRANS_TIME 20 |
Definition at line 205 of file mpegtsenc.c.
Referenced by mpegts_write_header().
#define PCR_TIME_BASE 27000000 |
Definition at line 33 of file mpegtsenc.c.
Referenced by get_pcr(), and mpegts_write_header().
#define SDT_RETRANS_TIME 500 |
Definition at line 203 of file mpegtsenc.c.
Referenced by mpegts_write_header().
#define SECTION_LENGTH 1020 |
Definition at line 111 of file mpegtsenc.c.
Referenced by mpegts_write_pat(), mpegts_write_pmt(), and mpegts_write_sdt().
typedef struct MpegTSSection MpegTSSection |
typedef struct MpegTSService MpegTSService |
typedef struct MpegTSWrite MpegTSWrite |
typedef struct MpegTSWriteStream MpegTSWriteStream |
|
static |
Definition at line 754 of file mpegtsenc.c.
Referenced by mpegts_write_pes().
|
static |
Definition at line 663 of file mpegtsenc.c.
Referenced by mpegts_insert_pcr_only(), and mpegts_write_pes().
|
static |
Definition at line 762 of file mpegtsenc.c.
Referenced by mpegts_write_pes().
|
static |
Definition at line 447 of file mpegtsenc.c.
Referenced by mpegts_write_header().
|
static |
Definition at line 684 of file mpegtsenc.c.
Referenced by mpegts_write_pes().
|
static |
Definition at line 699 of file mpegtsenc.c.
Referenced by mpegts_write_pes().
|
static |
Definition at line 1079 of file mpegtsenc.c.
|
static |
Definition at line 472 of file mpegtsenc.c.
|
static |
Definition at line 961 of file mpegtsenc.c.
|
static |
Definition at line 220 of file mpegtsenc.c.
Referenced by retransmit_si_info().
|
static |
Definition at line 775 of file mpegtsenc.c.
Referenced by mpegts_write_end(), and mpegts_write_packet().
|
static |
Definition at line 237 of file mpegtsenc.c.
Referenced by retransmit_si_info().
|
static |
Definition at line 409 of file mpegtsenc.c.
Referenced by retransmit_si_info().
|
static |
Definition at line 114 of file mpegtsenc.c.
Referenced by mpegts_write_section1().
|
static |
Definition at line 169 of file mpegtsenc.c.
Referenced by mpegts_write_pat(), mpegts_write_pmt(), and mpegts_write_sdt().
|
inlinestatic |
Definition at line 160 of file mpegtsenc.c.
Referenced by mpegts_write_pat(), mpegts_write_pmt(), mpegts_write_sdt(), and mpegts_write_section1().
|
static |
Definition at line 393 of file mpegtsenc.c.
Referenced by mpegts_write_sdt().
|
static |
Definition at line 645 of file mpegtsenc.c.
Referenced by mpegts_write_pes().
|
static |
Definition at line 466 of file mpegtsenc.c.
Referenced by mpegts_write_header().
|
static |
Definition at line 738 of file mpegtsenc.c.
Referenced by mpegts_write_pes().
|
static |
Definition at line 669 of file mpegtsenc.c.
Referenced by mpegts_insert_pcr_only(), and mpegts_write_pes().
|
static |
Definition at line 723 of file mpegtsenc.c.
Referenced by mpegts_write_pes().
AVOutputFormat ff_mpegts_muxer |
Definition at line 1112 of file mpegtsenc.c.
|
static |
Definition at line 102 of file mpegtsenc.c.
|
static |
Definition at line 85 of file mpegtsenc.c.