1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-12-23 12:43:46 +02:00

lavc: replace some deprecated FF_*_TYPE with AV_PICTURE_TYPE_*

This commit is contained in:
Anton Khirnov 2011-09-01 16:57:20 +02:00
parent feedc0754b
commit e5b29c1f6b
3 changed files with 4 additions and 4 deletions

View File

@ -35,7 +35,7 @@ static av_cold int encode_init(AVCodecContext *avctx)
DPXContext *s = avctx->priv_data; DPXContext *s = avctx->priv_data;
avctx->coded_frame = &s->picture; avctx->coded_frame = &s->picture;
avctx->coded_frame->pict_type = FF_I_TYPE; avctx->coded_frame->pict_type = AV_PICTURE_TYPE_I;
avctx->coded_frame->key_frame = 1; avctx->coded_frame->key_frame = 1;
s->big_endian = 1; s->big_endian = 1;

View File

@ -1167,7 +1167,7 @@ static int mpeg_decode_update_thread_context(AVCodecContext *avctx, const AVCode
if (!ctx->mpeg_enc_ctx_allocated) if (!ctx->mpeg_enc_ctx_allocated)
memcpy(s + 1, s1 + 1, sizeof(Mpeg1Context) - sizeof(MpegEncContext)); memcpy(s + 1, s1 + 1, sizeof(Mpeg1Context) - sizeof(MpegEncContext));
if (!(s->pict_type == FF_B_TYPE || s->low_delay)) if (!(s->pict_type == AV_PICTURE_TYPE_B || s->low_delay))
s->picture_number++; s->picture_number++;
return 0; return 0;

View File

@ -539,7 +539,7 @@ int ff_mpeg_update_thread_context(AVCodecContext *dst, const AVCodecContext *src
s->last_pict_type= s1->pict_type; s->last_pict_type= s1->pict_type;
if (s1->current_picture_ptr) s->last_lambda_for[s1->pict_type] = s1->current_picture_ptr->f.quality; if (s1->current_picture_ptr) s->last_lambda_for[s1->pict_type] = s1->current_picture_ptr->f.quality;
if(s1->pict_type!=FF_B_TYPE){ if (s1->pict_type != AV_PICTURE_TYPE_B) {
s->last_non_b_pict_type= s1->pict_type; s->last_non_b_pict_type= s1->pict_type;
} }
} }
@ -2652,6 +2652,6 @@ void ff_set_qscale(MpegEncContext * s, int qscale)
void MPV_report_decode_progress(MpegEncContext *s) void MPV_report_decode_progress(MpegEncContext *s)
{ {
if (s->pict_type != FF_B_TYPE && !s->partitioned_frame && !s->error_occurred) if (s->pict_type != AV_PICTURE_TYPE_B && !s->partitioned_frame && !s->error_occurred)
ff_thread_report_progress((AVFrame*)s->current_picture_ptr, s->mb_y, 0); ff_thread_report_progress((AVFrame*)s->current_picture_ptr, s->mb_y, 0);
} }