X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=libavcodec%2Fflashsvenc.c;h=7e14e479902a83bf649e9bd887d50c2400c3ff75;hb=40cf1bbacc6220a0aa6bed5c331871d43f9ce370;hp=1cc010eff20aa29d4269b5b1f1246b3cd747534c;hpb=5d3addb937946eca5391e40b5e6308e74ac6f77b;p=ffmpeg diff --git a/libavcodec/flashsvenc.c b/libavcodec/flashsvenc.c index 1cc010eff20..7e14e479902 100644 --- a/libavcodec/flashsvenc.c +++ b/libavcodec/flashsvenc.c @@ -258,13 +258,21 @@ static int flashsv_encode_frame(AVCodecContext *avctx, AVPacket *pkt, //mark the frame type so the muxer can mux it correctly if (I_frame) { +#if FF_API_CODED_FRAME +FF_DISABLE_DEPRECATION_WARNINGS avctx->coded_frame->pict_type = AV_PICTURE_TYPE_I; avctx->coded_frame->key_frame = 1; +FF_ENABLE_DEPRECATION_WARNINGS +#endif s->last_key_frame = avctx->frame_number; ff_dlog(avctx, "Inserting keyframe at frame %d\n", avctx->frame_number); } else { +#if FF_API_CODED_FRAME +FF_DISABLE_DEPRECATION_WARNINGS avctx->coded_frame->pict_type = AV_PICTURE_TYPE_P; avctx->coded_frame->key_frame = 0; +FF_ENABLE_DEPRECATION_WARNINGS +#endif } if (I_frame)