Mercurial > libavcodec.hg
comparison mpeg12.c @ 8589:a29b5b5c3c9d libavcodec
Avoid using sub_id in mpeg1/2video.
author | michael |
---|---|
date | Tue, 13 Jan 2009 21:13:45 +0000 |
parents | 01ec89cc9a10 |
children | 7a463923ecd1 |
comparison
equal
deleted
inserted
replaced
8588:93dbb3999cc8 | 8589:a29b5b5c3c9d |
---|---|
1263 | 1263 |
1264 /* low_delay may be forced, in this case we will have B-frames | 1264 /* low_delay may be forced, in this case we will have B-frames |
1265 * that behave like P-frames. */ | 1265 * that behave like P-frames. */ |
1266 avctx->has_b_frames = !(s->low_delay); | 1266 avctx->has_b_frames = !(s->low_delay); |
1267 | 1267 |
1268 if(avctx->sub_id==1){//s->codec_id==avctx->codec_id==CODEC_ID | 1268 assert((avctx->sub_id==1) == (avctx->codec_id==CODEC_ID_MPEG1VIDEO)); |
1269 if(avctx->codec_id==CODEC_ID_MPEG1VIDEO){ | |
1269 //MPEG-1 fps | 1270 //MPEG-1 fps |
1270 avctx->time_base.den= ff_frame_rate_tab[s->frame_rate_index].num; | 1271 avctx->time_base.den= ff_frame_rate_tab[s->frame_rate_index].num; |
1271 avctx->time_base.num= ff_frame_rate_tab[s->frame_rate_index].den; | 1272 avctx->time_base.num= ff_frame_rate_tab[s->frame_rate_index].den; |
1272 //MPEG-1 aspect | 1273 //MPEG-1 aspect |
1273 avctx->sample_aspect_ratio= av_d2q( | 1274 avctx->sample_aspect_ratio= av_d2q( |