summaryrefslogtreecommitdiff
path: root/src/combined/ffmpeg/ff_video_decoder.c
diff options
context:
space:
mode:
authorDarren Salt <linux@youmustbejoking.demon.co.uk>2009-04-02 19:44:14 +0100
committerDarren Salt <linux@youmustbejoking.demon.co.uk>2009-04-02 19:44:14 +0100
commite7377d3869eb77ea29c4b6ed5722b4a4b59cf5d7 (patch)
tree5a378f5b2dcf2543df0ac3fd30c1dbc31c545a54 /src/combined/ffmpeg/ff_video_decoder.c
parent20ec585fdc3280fd2acd9ec6f544004544ceb76d (diff)
parent8e25d940125d48830914eed61fa1854d00b96cb3 (diff)
downloadxine-lib-e7377d3869eb77ea29c4b6ed5722b4a4b59cf5d7.tar.gz
xine-lib-e7377d3869eb77ea29c4b6ed5722b4a4b59cf5d7.tar.bz2
Merge.
Diffstat (limited to 'src/combined/ffmpeg/ff_video_decoder.c')
-rw-r--r--src/combined/ffmpeg/ff_video_decoder.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/combined/ffmpeg/ff_video_decoder.c b/src/combined/ffmpeg/ff_video_decoder.c
index 15b9f056d..2742e3f2e 100644
--- a/src/combined/ffmpeg/ff_video_decoder.c
+++ b/src/combined/ffmpeg/ff_video_decoder.c
@@ -1284,7 +1284,15 @@ static void ff_handle_buffer (ff_video_decoder_t *this, buf_element_t *buf) {
}
/* use externally provided video_step or fall back to stream's time_base otherwise */
- video_step_to_use = (this->video_step || !this->context->time_base.den) ? this->video_step : (int)(90000ll * this->context->ticks_per_frame * this->context->time_base.num / this->context->time_base.den);
+ video_step_to_use = (this->video_step || !this->context->time_base.den)
+ ? this->video_step
+ : (int)(90000ll
+#if LIBAVCODEC_VERSION_INT >= 0x341400
+ * this->context->ticks_per_frame
+#elif LIBAVCODEC_VERSION_INT >= 0x340000
+# warning Building without avcodec ticks_per_frame support; you should upgrade your libavcodec and recompile
+#endif
+ * this->context->time_base.num / this->context->time_base.den);
/* aspect ratio provided by ffmpeg, override previous setting */
if ((this->aspect_ratio_prio < 2) &&