Commit 7b2dba1c authored by Marton Balint's avatar Marton Balint Committed by Michael Niedermayer

dv: fix avpriv_dv_codec_profile with lowres > 0

Fixes ticket #44.
Signed-off-by: 's avatarMarton Balint <cus@passwd.hu>
Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent 084bd109
...@@ -287,9 +287,9 @@ const DVprofile* avpriv_dv_codec_profile(AVCodecContext* codec) ...@@ -287,9 +287,9 @@ const DVprofile* avpriv_dv_codec_profile(AVCodecContext* codec)
int i; int i;
for (i=0; i<FF_ARRAY_ELEMS(dv_profiles); i++) for (i=0; i<FF_ARRAY_ELEMS(dv_profiles); i++)
if (codec->height == dv_profiles[i].height && if (codec->coded_height == dv_profiles[i].height &&
codec->pix_fmt == dv_profiles[i].pix_fmt && codec->pix_fmt == dv_profiles[i].pix_fmt &&
codec->width == dv_profiles[i].width) codec->coded_width == dv_profiles[i].width)
return &dv_profiles[i]; return &dv_profiles[i];
return NULL; return NULL;
......
...@@ -251,10 +251,8 @@ static int dv_extract_video_info(DVDemuxContext *c, uint8_t* frame) ...@@ -251,10 +251,8 @@ static int dv_extract_video_info(DVDemuxContext *c, uint8_t* frame)
avpriv_set_pts_info(c->vst, 64, c->sys->time_base.num, avpriv_set_pts_info(c->vst, 64, c->sys->time_base.num,
c->sys->time_base.den); c->sys->time_base.den);
avctx->time_base= c->sys->time_base; avctx->time_base= c->sys->time_base;
if (!avctx->width){ if (!avctx->width)
avctx->width = c->sys->width; avcodec_set_dimensions(avctx, c->sys->width, c->sys->height);
avctx->height = c->sys->height;
}
avctx->pix_fmt = c->sys->pix_fmt; avctx->pix_fmt = c->sys->pix_fmt;
/* finding out SAR is a little bit messy */ /* finding out SAR is a little bit messy */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment