if (ret < 0)
return ret;
}
- s1->pict_type= s->pict_type;
+ if((s1->flags & PARSER_FLAG_USE_CODEC_TS) && s->avctx->time_base.den>0 && ret>=0){
+ av_assert1(s1->pts == AV_NOPTS_VALUE);
+ av_assert1(s1->dts == AV_NOPTS_VALUE);
+
+ s1->pts = av_rescale_q(s->time, (AVRational){1, s->avctx->time_base.den}, (AVRational){1, 1200000});
+ }
+
+ s1->pict_type = s->pict_type;
pc->first_picture = 0;
return ret;
}
{
struct Mp4vParseContext *pc = s->priv_data;
- pc->first_picture = 1;
- pc->enc.quant_precision=5;
+ ff_mpeg4videodec_static_init();
+
+ pc->first_picture = 1;
++ pc->enc.quant_precision = 5;
pc->enc.slice_context_count = 1;
+ pc->enc.showed_packed_warning = 1;
return 0;
}