From 1f3788c5e1a47fa9b0412902acba38c86b53bb63 Mon Sep 17 00:00:00 2001 From: Andreas Monzner Date: Sun, 14 May 2006 12:23:23 +0000 Subject: remove unneeded caching of caids, use an array for pidcache instead of std::map (safe memory) prepare for different video stream types.. (H264) ( NOT for dm7025 ) --- lib/dvb/pmt.cpp | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'lib/dvb/pmt.cpp') diff --git a/lib/dvb/pmt.cpp b/lib/dvb/pmt.cpp index 4af18020..11cda125 100644 --- a/lib/dvb/pmt.cpp +++ b/lib/dvb/pmt.cpp @@ -250,9 +250,12 @@ int eDVBServicePMTHandler::getProgramInfo(struct program &program) video.pid = (*es)->getPid(); audio.pid = (*es)->getPid(); + video.type = videoStream::vtMPEG2; switch ((*es)->getType()) { + case 0x1b: // AVC Video Stream (MPEG4 H264) + video.type = videoStream::vtMPEG4_H264; case 0x01: // MPEG 1 video case 0x02: // MPEG 2 video isvideo = 1; @@ -277,6 +280,13 @@ int eDVBServicePMTHandler::getProgramInfo(struct program &program) if ( program.textPid == -1 || (*es)->getPid() == cached_tpid ) program.textPid = (*es)->getPid(); break; + case DTS_DESCRIPTOR: + if (!isvideo) + { + isaudio = 1; + audio.type = audioStream::atDTS; + } + break; case AC3_DESCRIPTOR: if (!isvideo) { @@ -354,11 +364,15 @@ int eDVBServicePMTHandler::getProgramInfo(struct program &program) apid_mpeg = m_service->getCachePID(eDVBService::cAPID), pcrpid = m_service->getCachePID(eDVBService::cPCRPID), tpid = m_service->getCachePID(eDVBService::cTPID), + vpidtype = m_service->getCachePID(eDVBService::cVTYPE), cnt=0; + if ( vpidtype == -1 ) + vpidtype = videoStream::vtMPEG2; if ( vpid != -1 ) { videoStream s; s.pid = vpid; + s.type = vpidtype; program.videoStreams.push_back(s); ++cnt; } -- cgit v1.2.3