CGenPsi:: add EAC3 audio support, revork genpsi

This commit is contained in:
Jacek Jendrzej
2013-10-09 21:51:18 +02:00
parent 2e6276def7
commit d92ad1de0d
4 changed files with 242 additions and 193 deletions

View File

@@ -23,17 +23,19 @@
#define __genpsi_h__
#include <inttypes.h>
#define EN_TYPE_VIDEO 0x00
#define EN_TYPE_AUDIO 0x01
#define EN_TYPE_TELTEX 0x02
#define EN_TYPE_PCR 0x03
#define EN_TYPE_AVC 0x04
#define EN_TYPE_DVBSUB 0x06
#define EN_TYPE_VIDEO 0x00
#define EN_TYPE_AUDIO 0x01
#define EN_TYPE_TELTEX 0x02
#define EN_TYPE_PCR 0x03
#define EN_TYPE_AVC 0x04
#define EN_TYPE_DVBSUB 0x06
#define EN_TYPE_AUDIO_EAC3 0x07
class CGenPsi
{
private:
short nba, nsub;
static const unsigned int pmt_pid = 0xcc;
short nba, nsub, neac3;
uint16_t vpid;
uint8_t vtype;
uint16_t pcrpid;
@@ -41,10 +43,14 @@ class CGenPsi
char vtxtlang[3];
uint16_t apid[10];
short atypes[10];
char apid_lang[10][3];
uint16_t dvbsubpid[10];
char dvbsublang[10][3];
static int copy_template(uint8_t *dst, uint8_t *src, int len);
uint16_t eac3_pid[10];
char eac3_lang[10][3];
uint32_t calc_crc32psi(uint8_t *dst, const uint8_t *src, uint32_t len);
void build_pat(uint8_t* buffer);
void build_pmt(uint8_t* buffer);
public:
CGenPsi();