diff options
-rw-r--r-- | xine_input_vdr.c | 28 |
1 files changed, 25 insertions, 3 deletions
diff --git a/xine_input_vdr.c b/xine_input_vdr.c index 0ec6c613..bb7f3a61 100644 --- a/xine_input_vdr.c +++ b/xine_input_vdr.c @@ -4,7 +4,7 @@ * See the main source file 'xineliboutput.c' for copyright information and * how to reach the author. * - * $Id: xine_input_vdr.c,v 1.210 2009-01-09 22:51:35 rofafor Exp $ + * $Id: xine_input_vdr.c,v 1.211 2009-01-18 19:02:26 phintuka Exp $ * */ @@ -68,6 +68,7 @@ #include "xine_osd_command.h" #include "tools/pes.h" +#include "tools/ts.h" /***************************** DEFINES *********************************/ @@ -3761,8 +3762,8 @@ static int vdr_plugin_read_net_udp(vdr_input_plugin_t *this) } } else { /* Check for PES header */ - if(pkt_data[0] || pkt_data[1] || pkt_data[2] != 1) { - LOGMSG("received invalid UDP packet (PES header 0x000001 missing)"); + if(!DATA_IS_TS(pkt_data) && (pkt_data[0] || pkt_data[1] || pkt_data[2] != 1)) { + LOGMSG("received invalid UDP packet (TS sync byte or PES header missing)"); continue; } } @@ -4572,12 +4573,33 @@ static buf_element_t *preprocess_buf(vdr_input_plugin_t *this, buf_element_t *bu } /* + * ts_demux() + * + * MPEG TS processing + */ + +static void demux_ts(vdr_input_plugin_t *this, buf_element_t *buf) +{ + unsigned int ts_pid = ts_PID(buf->content); + + LOGMSG("Got TS packet, pid = %d", ts_pid); + + buf->free_buffer(buf); +} + +/* * Demux some buffers not supported by mpeg_block demuxer: + * - MPEG TS * - H.264 video * - DVB Subtitles */ static buf_element_t *demux_buf(vdr_input_plugin_t *this, buf_element_t *buf) { + if (DATA_IS_TS(buf->content)) { + demux_ts(this, buf); + return NULL; + } + #ifdef TEST_H264 /* H.264 */ if (IS_VIDEO_PACKET(buf->content)) { |