Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FFmpeg/FFmpeg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'libavcodec/h264dec.c')
-rw-r--r--libavcodec/h264dec.c14
1 files changed, 6 insertions, 8 deletions
diff --git a/libavcodec/h264dec.c b/libavcodec/h264dec.c
index d944a8ce93..323639dc19 100644
--- a/libavcodec/h264dec.c
+++ b/libavcodec/h264dec.c
@@ -406,15 +406,13 @@ av_cold int ff_h264_decode_init(AVCodecContext *avctx)
return AVERROR_UNKNOWN;
}
- if (avctx->codec_id == AV_CODEC_ID_H264) {
- if (avctx->ticks_per_frame == 1) {
- if(h->avctx->time_base.den < INT_MAX/2) {
- h->avctx->time_base.den *= 2;
- } else
- h->avctx->time_base.num /= 2;
- }
- avctx->ticks_per_frame = 2;
+ if (avctx->ticks_per_frame == 1) {
+ if(h->avctx->time_base.den < INT_MAX/2) {
+ h->avctx->time_base.den *= 2;
+ } else
+ h->avctx->time_base.num /= 2;
}
+ avctx->ticks_per_frame = 2;
if (avctx->extradata_size > 0 && avctx->extradata) {
ret = ff_h264_decode_extradata(avctx->extradata, avctx->extradata_size,