diff options
| author | James Stembridge <jstembridge@users.sourceforge.net> | 2004-02-09 22:13:54 +0000 |
|---|---|---|
| committer | James Stembridge <jstembridge@users.sourceforge.net> | 2004-02-09 22:13:54 +0000 |
| commit | ca689b36373e820c26caa4c1b34679ca1a6038be (patch) | |
| tree | 48dd691f480fcb859ef4cbd1fdf9da3c0e22fed5 /src/libxvid/xine_decoder.c | |
| parent | 5fbef27bfd3bbb0a391332836d3813b6f0186d74 (diff) | |
| download | xine-lib-ca689b36373e820c26caa4c1b34679ca1a6038be.tar.gz xine-lib-ca689b36373e820c26caa4c1b34679ca1a6038be.tar.bz2 | |
Only read frame duration when BUF_FLAG_FRAMERATE is set
CVS patchset: 6127
CVS date: 2004/02/09 22:13:54
Diffstat (limited to 'src/libxvid/xine_decoder.c')
| -rw-r--r-- | src/libxvid/xine_decoder.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/libxvid/xine_decoder.c b/src/libxvid/xine_decoder.c index 6acecf747..f8856edaa 100644 --- a/src/libxvid/xine_decoder.c +++ b/src/libxvid/xine_decoder.c @@ -85,13 +85,18 @@ static void xvid_decode_data (video_decoder_t *this_gen, buf_element_t *buf) { lprintf ("processing packet type = %08x, buf: %08x, buf->decoder_flags=%08x\n", buf->type, buf, buf->decoder_flags); + if (buf->decoder_flags & BUF_FLAG_FRAMERATE) { + this->frame_duration = buf->decoder_info[0]; + _x_stream_info_set(this->stream, XINE_STREAM_INFO_FRAME_DURATION, + this->video_step); + } + if (buf->decoder_flags & BUF_FLAG_STDHEADER) { xine_bmiheader *bih; XVID_DEC_PARAM xparam; /* initialize data describing video stream */ bih = (xine_bmiheader *) buf->content; - this->frame_duration = buf->decoder_info[1]; this->frame_width = bih->biWidth; this->frame_height = bih->biHeight; this->ratio = (double)bih->biWidth/(double)bih->biHeight; |
