From 491f443e1f7ebcc8bf8be434ad7c383f5647aff9 Mon Sep 17 00:00:00 2001 From: Anton Khirnov Date: Sun, 22 Jan 2012 10:56:42 +0100 Subject: [PATCH] lavc: remove disabled FF_API_ER cruft. --- libavcodec/avcodec.h | 15 --------------- libavcodec/options.c | 8 -------- libavcodec/utils.c | 10 ---------- libavcodec/version.h | 3 --- 4 files changed, 36 deletions(-) diff --git a/libavcodec/avcodec.h b/libavcodec/avcodec.h index d4a1939f70e..fa9dba7277b 100644 --- a/libavcodec/avcodec.h +++ b/libavcodec/avcodec.h @@ -1545,21 +1545,6 @@ typedef struct AVCodecContext { */ float b_quant_offset; -#if FF_API_ER - /** - * Error recognition; higher values will detect more errors but may - * misdetect some more or less valid parts as errors. - * - encoding: unused - * - decoding: Set by user. - */ - attribute_deprecated int error_recognition; -#define FF_ER_CAREFUL 1 -#define FF_ER_COMPLIANT 2 -#define FF_ER_AGGRESSIVE 3 -#define FF_ER_VERY_AGGRESSIVE 4 -#define FF_ER_EXPLODE 5 -#endif /* FF_API_ER */ - /** * Called at the beginning of each frame to get a buffer for it. * diff --git a/libavcodec/options.c b/libavcodec/options.c index 1ccc73fe887..17aa69ae355 100644 --- a/libavcodec/options.c +++ b/libavcodec/options.c @@ -177,14 +177,6 @@ static const AVOption options[]={ {"unofficial", "allow unofficial extensions", 0, AV_OPT_TYPE_CONST, {.dbl = FF_COMPLIANCE_UNOFFICIAL }, INT_MIN, INT_MAX, V|D|E, "strict"}, {"experimental", "allow non standardized experimental things", 0, AV_OPT_TYPE_CONST, {.dbl = FF_COMPLIANCE_EXPERIMENTAL }, INT_MIN, INT_MAX, V|D|E, "strict"}, {"b_qoffset", "qp offset between P and B frames", OFFSET(b_quant_offset), AV_OPT_TYPE_FLOAT, {.dbl = 1.25 }, -FLT_MAX, FLT_MAX, V|E}, -#if FF_API_ER -{"er", "set error detection aggressivity", OFFSET(error_recognition), AV_OPT_TYPE_INT, {.dbl = FF_ER_CAREFUL }, INT_MIN, INT_MAX, A|V|D, "er"}, -{"careful", NULL, 0, AV_OPT_TYPE_CONST, {.dbl = FF_ER_CAREFUL }, INT_MIN, INT_MAX, V|D, "er"}, -{"compliant", NULL, 0, AV_OPT_TYPE_CONST, {.dbl = FF_ER_COMPLIANT }, INT_MIN, INT_MAX, V|D, "er"}, -{"aggressive", NULL, 0, AV_OPT_TYPE_CONST, {.dbl = FF_ER_AGGRESSIVE }, INT_MIN, INT_MAX, V|D, "er"}, -{"very_aggressive", NULL, 0, AV_OPT_TYPE_CONST, {.dbl = FF_ER_VERY_AGGRESSIVE }, INT_MIN, INT_MAX, V|D, "er"}, -{"explode", "abort decoding on error recognition", 0, AV_OPT_TYPE_CONST, {.dbl = FF_ER_EXPLODE }, INT_MIN, INT_MAX, V|D, "er"}, -#endif /* FF_API_ER */ {"err_detect", "set error detection flags", OFFSET(err_recognition), AV_OPT_TYPE_FLAGS, {.dbl = AV_EF_CRCCHECK }, INT_MIN, INT_MAX, A|V|D, "err_detect"}, {"crccheck", "verify embedded CRCs", 0, AV_OPT_TYPE_CONST, {.dbl = AV_EF_CRCCHECK }, INT_MIN, INT_MAX, V|D, "err_detect"}, {"bitstream", "detect bitstream specification deviations", 0, AV_OPT_TYPE_CONST, {.dbl = AV_EF_BITSTREAM }, INT_MIN, INT_MAX, V|D, "err_detect"}, diff --git a/libavcodec/utils.c b/libavcodec/utils.c index 6236f79831a..7c0f18aa343 100644 --- a/libavcodec/utils.c +++ b/libavcodec/utils.c @@ -716,16 +716,6 @@ int attribute_align_arg avcodec_open2(AVCodecContext *avctx, AVCodec *codec, AVD goto free_and_end; } avctx->frame_number = 0; -#if FF_API_ER - - av_log(avctx, AV_LOG_DEBUG, "err{or,}_recognition separate: %d; %d\n", - avctx->error_recognition, avctx->err_recognition); - /* FF_ER_CAREFUL (==1) implies AV_EF_CRCCHECK (== 1<<1 - 1), - FF_ER_COMPLIANT (==2) implies AV_EF_{CRCCHECK,BITSTREAM} (== 1<<2 - 1), et cetera} */ - avctx->err_recognition |= (1<<(avctx->error_recognition-(avctx->error_recognition>=FF_ER_VERY_AGGRESSIVE))) - 1; - av_log(avctx, AV_LOG_DEBUG, "err{or,}_recognition combined: %d; %d\n", - avctx->error_recognition, avctx->err_recognition); -#endif if (HAVE_THREADS && !avctx->thread_opaque) { ret = ff_thread_init(avctx); diff --git a/libavcodec/version.h b/libavcodec/version.h index 363d79a9240..e19de49d16e 100644 --- a/libavcodec/version.h +++ b/libavcodec/version.h @@ -41,9 +41,6 @@ #ifndef FF_API_REQUEST_CHANNELS #define FF_API_REQUEST_CHANNELS (LIBAVCODEC_VERSION_MAJOR < 55) #endif -#ifndef FF_API_ER -#define FF_API_ER (LIBAVCODEC_VERSION_MAJOR < 54) -#endif #ifndef FF_API_AVCODEC_INIT #define FF_API_AVCODEC_INIT (LIBAVCODEC_VERSION_MAJOR < 54) #endif -- 2.39.2