X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=libavcodec%2Flibxavs.c;h=0f22016731a945c054d4b08ec7d9e984dc829a8b;hb=eb6ea948ed2f86361ae0b9d8689368d466b8337f;hp=801a05dbb581a012860b32c91dd14e129b753f4b;hpb=4f9a8d3fe2f9485ee08848d336ee96f15ec0e7e6;p=ffmpeg diff --git a/libavcodec/libxavs.c b/libavcodec/libxavs.c index 801a05dbb58..0f22016731a 100644 --- a/libavcodec/libxavs.c +++ b/libavcodec/libxavs.c @@ -28,6 +28,7 @@ #include #include "avcodec.h" #include "internal.h" +#include "packet_internal.h" #include "libavutil/internal.h" #include "libavutil/mem.h" #include "libavutil/opt.h" @@ -287,13 +288,6 @@ static av_cold int XAVS_init(AVCodecContext *avctx) /* cabac is not included in AVS JiZhun Profile */ x4->params.b_cabac = 0; -#if FF_API_PRIVATE_OPT -FF_DISABLE_DEPRECATION_WARNINGS - if (avctx->b_frame_strategy) - x4->b_frame_strategy = avctx->b_frame_strategy; -FF_ENABLE_DEPRECATION_WARNINGS -#endif - x4->params.i_bframe_adaptive = x4->b_frame_strategy; avctx->has_b_frames = !!avctx->max_b_frames; @@ -304,13 +298,6 @@ FF_ENABLE_DEPRECATION_WARNINGS if (x4->params.i_keyint_min > x4->params.i_keyint_max) x4->params.i_keyint_min = x4->params.i_keyint_max; -#if FF_API_PRIVATE_OPT -FF_DISABLE_DEPRECATION_WARNINGS - if (avctx->scenechange_threshold) - x4->scenechange_threshold = avctx->scenechange_threshold; -FF_ENABLE_DEPRECATION_WARNINGS -#endif - x4->params.i_scenecut_threshold = x4->scenechange_threshold; // x4->params.b_deblocking_filter = avctx->flags & AV_CODEC_FLAG_LOOP_FILTER; @@ -342,13 +329,6 @@ FF_ENABLE_DEPRECATION_WARNINGS x4->params.analyse.i_trellis = avctx->trellis; -#if FF_API_PRIVATE_OPT - FF_DISABLE_DEPRECATION_WARNINGS - if (avctx->noise_reduction >= 0) - x4->noise_reduction = avctx->noise_reduction; - FF_ENABLE_DEPRECATION_WARNINGS -#endif - x4->params.analyse.i_noise_reduction = x4->noise_reduction; if (avctx->level > 0) @@ -370,13 +350,6 @@ FF_ENABLE_DEPRECATION_WARNINGS x4->params.rc.f_ip_factor = 1 / fabs(avctx->i_quant_factor); x4->params.rc.f_pb_factor = avctx->b_quant_factor; -#if FF_API_PRIVATE_OPT -FF_DISABLE_DEPRECATION_WARNINGS - if (avctx->chromaoffset) - x4->chroma_offset = avctx->chromaoffset; -FF_ENABLE_DEPRECATION_WARNINGS -#endif - x4->params.analyse.i_chroma_qp_offset = x4->chroma_offset; x4->params.analyse.b_psnr = avctx->flags & AV_CODEC_FLAG_PSNR; @@ -474,7 +447,8 @@ AVCodec ff_libxavs_encoder = { .init = XAVS_init, .encode2 = XAVS_frame, .close = XAVS_close, - .capabilities = AV_CODEC_CAP_DELAY | AV_CODEC_CAP_AUTO_THREADS, + .capabilities = AV_CODEC_CAP_DELAY | AV_CODEC_CAP_OTHER_THREADS, + .caps_internal = FF_CODEC_CAP_AUTO_THREADS, .pix_fmts = (const enum AVPixelFormat[]) { AV_PIX_FMT_YUV420P, AV_PIX_FMT_NONE }, .priv_class = &xavs_class, .defaults = xavs_defaults,