pmt.cpp: more streamtype detection fixes (?!?)
authorghost <andreas.monzner@multimedia-labs.de>
Sun, 26 Jul 2009 06:54:28 +0000 (08:54 +0200)
committerghost <andreas.monzner@multimedia-labs.de>
Sun, 26 Jul 2009 06:54:28 +0000 (08:54 +0200)
dont handle pids with teletext descriptor as audio/video

lib/dvb/pmt.cpp

index e1aa096..833a521 100644 (file)
@@ -460,11 +460,16 @@ int eDVBServicePMTHandler::getProgramInfo(struct program &program)
                                        default:
                                                break;
                                        }
                                        default:
                                                break;
                                        }
-                                       if (issubtitle && (isaudio || isvideo))
+                                       if (program.textPid != -1 && (isaudio || isvideo)) 
+                                       {
+                                               eDebug("ambiguous streamtype for PID %04x detected.. forced as teletext!", (*es)->getPid());                                    
+                                               continue; // continue with next PID
+                                       }
+                                       else if (issubtitle && (isaudio || isvideo))
                                                eDebug("ambiguous streamtype for PID %04x detected.. forced as subtitle!", (*es)->getPid());
                                        else if (isaudio && isvideo)
                                                eDebug("ambiguous streamtype for PID %04x detected.. forced as video!", (*es)->getPid());
                                                eDebug("ambiguous streamtype for PID %04x detected.. forced as subtitle!", (*es)->getPid());
                                        else if (isaudio && isvideo)
                                                eDebug("ambiguous streamtype for PID %04x detected.. forced as video!", (*es)->getPid());
-                                       if (issubtitle)
+                                       if (issubtitle) // continue with next PID
                                                continue;
                                        else if (isvideo)
                                        {
                                                continue;
                                        else if (isvideo)
                                        {