diff options
Diffstat (limited to 'src/libmpeg2/xine_decoder.c')
-rw-r--r-- | src/libmpeg2/xine_decoder.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/src/libmpeg2/xine_decoder.c b/src/libmpeg2/xine_decoder.c index ce4788d85..6783f7d20 100644 --- a/src/libmpeg2/xine_decoder.c +++ b/src/libmpeg2/xine_decoder.c @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA * - * $Id: xine_decoder.c,v 1.6 2001/06/07 20:23:54 guenter Exp $ + * $Id: xine_decoder.c,v 1.7 2001/06/09 22:05:31 guenter Exp $ * * stuff needed to turn libmpeg2 into a xine decoder plugin */ @@ -55,8 +55,12 @@ static void mpeg2dec_init (video_decoder_t *this_gen, vo_instance_t *video_out) static void mpeg2dec_decode_data (video_decoder_t *this_gen, buf_element_t *buf) { mpeg2dec_decoder_t *this = (mpeg2dec_decoder_t *) this_gen; - mpeg2_decode_data (&this->mpeg2, buf->content, buf->content + buf->size, - buf->PTS); + if (buf->decoder_info[0] == 0) { + mpeg2_find_sequence_header (&this->mpeg2, buf->content, buf->content + buf->size); + } else { + mpeg2_decode_data (&this->mpeg2, buf->content, buf->content + buf->size, + buf->PTS); + } } static void mpeg2dec_close (video_decoder_t *this_gen) { |