diff options
author | Klaus Schmidinger <vdr@tvdr.de> | 2012-09-19 10:46:17 +0200 |
---|---|---|
committer | Klaus Schmidinger <vdr@tvdr.de> | 2012-09-19 10:46:17 +0200 |
commit | e11908cae65545d320f3e0949a9e8c5b426c5b78 (patch) | |
tree | 778f4ea5a87903ad497534763078c76623edf180 /remux.c | |
parent | ed456adc80fdc7760805aa08f4d81146d3ec5576 (diff) | |
download | vdr-e11908cae65545d320f3e0949a9e8c5b426c5b78.tar.gz vdr-e11908cae65545d320f3e0949a9e8c5b426c5b78.tar.bz2 |
cPatPmtParser::ParsePmt() now also recognizes stream type 0x81 as "AC3"
Diffstat (limited to 'remux.c')
-rw-r--r-- | remux.c | 30 |
1 files changed, 29 insertions, 1 deletions
@@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: remux.c 2.66 2012/09/18 09:11:24 kls Exp $ + * $Id: remux.c 2.67 2012/09/19 10:28:42 kls Exp $ */ #include "remux.h" @@ -622,6 +622,34 @@ void cPatPmtParser::ParsePmt(const uchar *Data, int Length) } } break; + case 0x81: // STREAMTYPE_USER_PRIVATE + { + dbgpatpmt(" AC3"); + char lang[MAXLANGCODE1] = { 0 }; + SI::Descriptor *d; + for (SI::Loop::Iterator it; (d = stream.streamDescriptors.getNext(it)); ) { + switch (d->getDescriptorTag()) { + case SI::ISO639LanguageDescriptorTag: { + SI::ISO639LanguageDescriptor *ld = (SI::ISO639LanguageDescriptor *)d; + dbgpatpmt(" '%s'", ld->languageCode); + strn0cpy(lang, I18nNormalizeLanguageCode(ld->languageCode), MAXLANGCODE1); + } + break; + default: ; + } + delete d; + } + if (NumDpids < MAXDPIDS) { + dpids[NumDpids] = stream.getPid(); + dtypes[NumDpids] = SI::AC3DescriptorTag; + strn0cpy(dlangs[NumDpids], lang, sizeof(dlangs[NumDpids])); + if (updatePrimaryDevice && Setup.UseDolbyDigital) + cDevice::PrimaryDevice()->SetAvailableTrack(ttDolby, NumDpids, stream.getPid(), lang); + NumDpids++; + dpids[NumDpids]= 0; + } + } + break; default: ; } dbgpatpmt("\n"); |