vdr  1.7.31
Macros | Functions | Variables
remux.c File Reference
#include "remux.h"
#include "device.h"
#include "libsi/si.h"
#include "libsi/section.h"
#include "libsi/descriptor.h"
#include "recording.h"
#include "shutdown.h"
#include "tools.h"

Go to the source code of this file.

Macros

#define dbgpatpmt(a...)   if (DebugPatPmt) fprintf(stderr, a)
#define dbgframes(a...)   if (DebugFrames) fprintf(stderr, a)
#define VIDEO_STREAM_S   0xE0
#define P_TSID   0x8008
#define P_PMT_PID   0x0084
#define MAXPID   0x2000
#define SETPID(p)   { if ((p) >= 0 && (p) < MAXPID) Used[p] = true; }
#define SETPIDS(l)   { const int *p = l; while (*p) { SETPID(*p); p++; } }
#define MAXPESLENGTH   0xFFF0
#define EMPTY_SCANNER   (0xFFFFFFFF)

Functions

ePesHeader AnalyzePesHeader (const uchar *Data, int Count, int &PesPayloadOffset, bool *ContinuationHeader)
int64_t TsGetPts (const uchar *p, int l)
void TsSetTeiOnBrokenPackets (uchar *p, int l)
void BlockDump (const char *Name, const u_char *Data, int Length)
void TsDump (const char *Name, const u_char *Data, int Length)
void PesDump (const char *Name, const u_char *Data, int Length)
static int CmpUint32 (const void *p1, const void *p2)

Variables

static bool DebugPatPmt = false
static bool DebugFrames = false

Macro Definition Documentation

#define dbgframes (   a...)    if (DebugFrames) fprintf(stderr, a)

Definition at line 24 of file remux.c.

Referenced by cFrameDetector::Analyze(), and cFrameDetector::SkipPackets().

#define dbgpatpmt (   a...)    if (DebugPatPmt) fprintf(stderr, a)

Definition at line 23 of file remux.c.

Referenced by cPatPmtParser::ParsePat(), and cPatPmtParser::ParsePmt().

#define EMPTY_SCANNER   (0xFFFFFFFF)
#define MAXPESLENGTH   0xFFF0

Definition at line 769 of file remux.c.

Referenced by cTsToPes::GetPes().

#define MAXPID   0x2000

Definition at line 277 of file remux.c.

Referenced by cPatPmtGenerator::GeneratePmtPid(), and TsSetTeiOnBrokenPackets().

#define P_PMT_PID   0x0084

Definition at line 276 of file remux.c.

Referenced by cPatPmtGenerator::GeneratePmtPid().

#define P_TSID   0x8008

Definition at line 275 of file remux.c.

Referenced by cPatPmtGenerator::GeneratePat().

#define SETPID (   p)    { if ((p) >= 0 && (p) < MAXPID) Used[p] = true; }
#define SETPIDS (   l)    { const int *p = l; while (*p) { SETPID(*p); p++; } }
#define VIDEO_STREAM_S   0xE0

Definition at line 92 of file remux.c.

Referenced by cRemux::SetBrokenLink().

Function Documentation

ePesHeader AnalyzePesHeader ( const uchar Data,
int  Count,
int &  PesPayloadOffset,
bool *  ContinuationHeader 
)

Definition at line 26 of file remux.c.

References phInvalid, phMPEG1, phMPEG2, and phNeedMoreData.

Referenced by cRemux::SetBrokenLink().

void BlockDump ( const char *  Name,
const u_char *  Data,
int  Length 
)

Definition at line 834 of file remux.c.

static int CmpUint32 ( const void *  p1,
const void *  p2 
)
static

Definition at line 884 of file remux.c.

Referenced by cFrameDetector::Analyze().

void PesDump ( const char *  Name,
const u_char *  Data,
int  Length 
)

Definition at line 860 of file remux.c.

References TsDump().

void TsDump ( const char *  Name,
const u_char *  Data,
int  Length 
)

Definition at line 845 of file remux.c.

References max(), and min().

Referenced by PesDump().

int64_t TsGetPts ( const uchar p,
int  l 
)

Definition at line 115 of file remux.c.

References PesGetPts(), PesHasPts(), TS_SIZE, TsGetPayload(), and TsPayloadStart().

Referenced by cDvbPlayer::Action(), and cDvbPlayer::Goto().

void TsSetTeiOnBrokenPackets ( uchar p,
int  l 
)

Variable Documentation

bool DebugFrames = false
static

Definition at line 21 of file remux.c.

Referenced by cFrameDetector::Analyze().

bool DebugPatPmt = false
static

Definition at line 20 of file remux.c.