Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
 help / color / mirror / Atom feed
* [FFmpeg-devel] [PATCH 1/7] avcodec/error_resilience: Only keep what is needed from MECmpContext
@ 2022-05-16 18:36 Andreas Rheinhardt
  2022-05-16 18:38 ` [FFmpeg-devel] [PATCH 2/7] avcodec/mss2: Remove write-only QpelDSPContext Andreas Rheinhardt
                   ` (5 more replies)
  0 siblings, 6 replies; 8+ messages in thread
From: Andreas Rheinhardt @ 2022-05-16 18:36 UTC (permalink / raw)
  To: ffmpeg-devel; +Cc: Andreas Rheinhardt

ERContext currently has an embedded MECmpContext, despite only
needing exactly one function from it. This is wasteful because
MECmpContext is pretty large (135 pointers, 1080 B for eight byte
pointers). So keep only what is needed.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
---
 libavcodec/error_resilience.c | 14 ++++++++------
 libavcodec/error_resilience.h |  3 ++-
 2 files changed, 10 insertions(+), 7 deletions(-)

diff --git a/libavcodec/error_resilience.c b/libavcodec/error_resilience.c
index e9764f8d96..f957c68d2c 100644
--- a/libavcodec/error_resilience.c
+++ b/libavcodec/error_resilience.c
@@ -766,12 +766,12 @@ static int is_intra_more_likely(ERContext *s)
                 } else {
                     ff_thread_await_progress(s->last_pic.tf, mb_y, 0);
                 }
-                is_intra_likely += s->mecc.sad[0](NULL, last_mb_ptr, mb_ptr,
-                                                  linesize[0], 16);
+                is_intra_likely += s->sad(NULL, last_mb_ptr, mb_ptr,
+                                          linesize[0], 16);
                 // FIXME need await_progress() here
-                is_intra_likely -= s->mecc.sad[0](NULL, last_mb_ptr,
-                                                  last_mb_ptr + linesize[0] * 16,
-                                                  linesize[0], 16);
+                is_intra_likely -= s->sad(NULL, last_mb_ptr,
+                                          last_mb_ptr + linesize[0] * 16,
+                                          linesize[0], 16);
             } else {
                 if (IS_INTRA(s->cur_pic.mb_type[mb_xy]))
                    is_intra_likely++;
@@ -790,7 +790,9 @@ void ff_er_frame_start(ERContext *s)
         return;
 
     if (!s->mecc_inited) {
-        ff_me_cmp_init(&s->mecc, s->avctx);
+        MECmpContext mecc;
+        ff_me_cmp_init(&mecc, s->avctx);
+        s->sad = mecc.sad[0];
         s->mecc_inited = 1;
     }
 
diff --git a/libavcodec/error_resilience.h b/libavcodec/error_resilience.h
index 2187586618..53e5cf2621 100644
--- a/libavcodec/error_resilience.h
+++ b/libavcodec/error_resilience.h
@@ -52,7 +52,8 @@ typedef struct ERPicture {
 
 typedef struct ERContext {
     AVCodecContext *avctx;
-    MECmpContext mecc;
+
+    me_cmp_func sad;
     int mecc_inited;
 
     int *mb_index2xy;
-- 
2.32.0

_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [FFmpeg-devel] [PATCH 2/7] avcodec/mss2: Remove write-only QpelDSPContext
  2022-05-16 18:36 [FFmpeg-devel] [PATCH 1/7] avcodec/error_resilience: Only keep what is needed from MECmpContext Andreas Rheinhardt
@ 2022-05-16 18:38 ` Andreas Rheinhardt
  2022-05-16 18:38 ` [FFmpeg-devel] [PATCH 3/7] avcodec/mpegvideo: Move float.h inclusion to mpegvideoenc.h Andreas Rheinhardt
                   ` (4 subsequent siblings)
  5 siblings, 0 replies; 8+ messages in thread
From: Andreas Rheinhardt @ 2022-05-16 18:38 UTC (permalink / raw)
  To: ffmpeg-devel; +Cc: Andreas Rheinhardt

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
---
 libavcodec/mss2.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/libavcodec/mss2.c b/libavcodec/mss2.c
index ab42d12217..228f66afc0 100644
--- a/libavcodec/mss2.c
+++ b/libavcodec/mss2.c
@@ -42,7 +42,6 @@ typedef struct MSS2Context {
     AVFrame       *last_pic;
     MSS12Context   c;
     MSS2DSPContext dsp;
-    QpelDSPContext qdsp;
     SliceContext   sc[2];
 } MSS2Context;
 
@@ -837,7 +836,6 @@ static av_cold int mss2_decode_init(AVCodecContext *avctx)
         return ret;
     }
     ff_mss2dsp_init(&ctx->dsp);
-    ff_qpeldsp_init(&ctx->qdsp);
 
     avctx->pix_fmt = c->free_colours == 127 ? AV_PIX_FMT_RGB555
                                             : AV_PIX_FMT_RGB24;
-- 
2.32.0

_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [FFmpeg-devel] [PATCH 3/7] avcodec/mpegvideo: Move float.h inclusion to mpegvideoenc.h
  2022-05-16 18:36 [FFmpeg-devel] [PATCH 1/7] avcodec/error_resilience: Only keep what is needed from MECmpContext Andreas Rheinhardt
  2022-05-16 18:38 ` [FFmpeg-devel] [PATCH 2/7] avcodec/mss2: Remove write-only QpelDSPContext Andreas Rheinhardt
@ 2022-05-16 18:38 ` Andreas Rheinhardt
  2022-05-16 18:38 ` [FFmpeg-devel] [PATCH 4/7] avcodec/mpegvideoenc: Remove ineffective [pb]bias options Andreas Rheinhardt
                   ` (3 subsequent siblings)
  5 siblings, 0 replies; 8+ messages in thread
From: Andreas Rheinhardt @ 2022-05-16 18:38 UTC (permalink / raw)
  To: ffmpeg-devel; +Cc: Andreas Rheinhardt

It is only needed for the options in mpegvideoenc.h.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
---
 libavcodec/mpegvideo.h    | 2 --
 libavcodec/mpegvideoenc.h | 2 ++
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/libavcodec/mpegvideo.h b/libavcodec/mpegvideo.h
index 0f816e5807..a832369f7f 100644
--- a/libavcodec/mpegvideo.h
+++ b/libavcodec/mpegvideo.h
@@ -28,8 +28,6 @@
 #ifndef AVCODEC_MPEGVIDEO_H
 #define AVCODEC_MPEGVIDEO_H
 
-#include <float.h>
-
 #include "avcodec.h"
 #include "blockdsp.h"
 #include "error_resilience.h"
diff --git a/libavcodec/mpegvideoenc.h b/libavcodec/mpegvideoenc.h
index fae41457bf..a0e8913ea6 100644
--- a/libavcodec/mpegvideoenc.h
+++ b/libavcodec/mpegvideoenc.h
@@ -28,6 +28,8 @@
 #ifndef AVCODEC_MPEGVIDEOENC_H
 #define AVCODEC_MPEGVIDEOENC_H
 
+#include <float.h>
+
 #include "libavutil/opt.h"
 #include "mpegvideo.h"
 
-- 
2.32.0

_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [FFmpeg-devel] [PATCH 4/7] avcodec/mpegvideoenc: Remove ineffective [pb]bias options
  2022-05-16 18:36 [FFmpeg-devel] [PATCH 1/7] avcodec/error_resilience: Only keep what is needed from MECmpContext Andreas Rheinhardt
  2022-05-16 18:38 ` [FFmpeg-devel] [PATCH 2/7] avcodec/mss2: Remove write-only QpelDSPContext Andreas Rheinhardt
  2022-05-16 18:38 ` [FFmpeg-devel] [PATCH 3/7] avcodec/mpegvideo: Move float.h inclusion to mpegvideoenc.h Andreas Rheinhardt
@ 2022-05-16 18:38 ` Andreas Rheinhardt
  2022-05-19 18:16   ` Andreas Rheinhardt
  2022-05-16 18:38 ` [FFmpeg-devel] [PATCH 5/7] avcodec/mjpegenc: Remove pointless motion-estimation options Andreas Rheinhardt
                   ` (2 subsequent siblings)
  5 siblings, 1 reply; 8+ messages in thread
From: Andreas Rheinhardt @ 2022-05-16 18:38 UTC (permalink / raw)
  To: ffmpeg-devel; +Cc: Andreas Rheinhardt

The user-provided value is overwritten in ff_mpv_encode_init()
without having ever been read.
(This has been broken when making these options mpegvideo-specific
in commits 910247f1720c6aae422723c05dac6d0b19f20bec and
cf7d2f2d2134c0854edf2db91e7436ac2bc9874f. No one has ever complained,
so this commit removes these fields.)

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
---
 libavcodec/mpegvideoenc.h | 4 ----
 libavcodec/version.h      | 2 +-
 2 files changed, 1 insertion(+), 5 deletions(-)

diff --git a/libavcodec/mpegvideoenc.h b/libavcodec/mpegvideoenc.h
index a0e8913ea6..ecc389a6d3 100644
--- a/libavcodec/mpegvideoenc.h
+++ b/libavcodec/mpegvideoenc.h
@@ -43,8 +43,6 @@
 #define FF_MPV_FLAG_NAQ          0x0010
 #define FF_MPV_FLAG_MV0          0x0020
 
-#define FF_DEFAULT_QUANT_BIAS 999999
-
 #define FF_MPV_OPT_CMP_FUNC \
 { "sad",    "Sum of absolute differences, fast", 0, AV_OPT_TYPE_CONST, {.i64 = FF_CMP_SAD }, INT_MIN, INT_MAX, FF_MPV_OPT_FLAGS, "cmp_func" }, \
 { "sse",    "Sum of squared errors", 0, AV_OPT_TYPE_CONST, {.i64 = FF_CMP_SSE }, INT_MIN, INT_MAX, FF_MPV_OPT_FLAGS, "cmp_func" }, \
@@ -94,8 +92,6 @@ FF_MPV_OPT_CMP_FUNC, \
 {"border_mask", "increase the quantizer for macroblocks close to borders", FF_MPV_OFFSET(border_masking), AV_OPT_TYPE_FLOAT, {.dbl = 0 }, -FLT_MAX, FLT_MAX, FF_MPV_OPT_FLAGS},    \
 {"lmin", "minimum Lagrange factor (VBR)",                           FF_MPV_OFFSET(lmin), AV_OPT_TYPE_INT, {.i64 =  2*FF_QP2LAMBDA }, 0, INT_MAX, FF_MPV_OPT_FLAGS },            \
 {"lmax", "maximum Lagrange factor (VBR)",                           FF_MPV_OFFSET(lmax), AV_OPT_TYPE_INT, {.i64 = 31*FF_QP2LAMBDA }, 0, INT_MAX, FF_MPV_OPT_FLAGS },            \
-{"ibias", "intra quant bias",                                       FF_MPV_OFFSET(intra_quant_bias), AV_OPT_TYPE_INT, {.i64 = FF_DEFAULT_QUANT_BIAS }, INT_MIN, INT_MAX, FF_MPV_OPT_FLAGS },   \
-{"pbias", "inter quant bias",                                       FF_MPV_OFFSET(inter_quant_bias), AV_OPT_TYPE_INT, {.i64 = FF_DEFAULT_QUANT_BIAS }, INT_MIN, INT_MAX, FF_MPV_OPT_FLAGS },   \
 {"motion_est", "motion estimation algorithm",                       FF_MPV_OFFSET(motion_est), AV_OPT_TYPE_INT, {.i64 = FF_ME_EPZS }, FF_ME_ZERO, FF_ME_XONE, FF_MPV_OPT_FLAGS, "motion_est" },   \
 { "zero", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = FF_ME_ZERO }, 0, 0, FF_MPV_OPT_FLAGS, "motion_est" }, \
 { "epzs", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = FF_ME_EPZS }, 0, 0, FF_MPV_OPT_FLAGS, "motion_est" }, \
diff --git a/libavcodec/version.h b/libavcodec/version.h
index 87b7284a95..5183deb68b 100644
--- a/libavcodec/version.h
+++ b/libavcodec/version.h
@@ -29,7 +29,7 @@
 
 #include "version_major.h"
 
-#define LIBAVCODEC_VERSION_MINOR  28
+#define LIBAVCODEC_VERSION_MINOR  29
 #define LIBAVCODEC_VERSION_MICRO 100
 
 #define LIBAVCODEC_VERSION_INT  AV_VERSION_INT(LIBAVCODEC_VERSION_MAJOR, \
-- 
2.32.0

_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [FFmpeg-devel] [PATCH 5/7] avcodec/mjpegenc: Remove pointless motion-estimation options
  2022-05-16 18:36 [FFmpeg-devel] [PATCH 1/7] avcodec/error_resilience: Only keep what is needed from MECmpContext Andreas Rheinhardt
                   ` (2 preceding siblings ...)
  2022-05-16 18:38 ` [FFmpeg-devel] [PATCH 4/7] avcodec/mpegvideoenc: Remove ineffective [pb]bias options Andreas Rheinhardt
@ 2022-05-16 18:38 ` Andreas Rheinhardt
  2022-05-16 18:38 ` [FFmpeg-devel] [PATCH 6/7] avcodec/mpegvideoenc: Remove ineffective options Andreas Rheinhardt
  2022-05-16 18:39 ` [FFmpeg-devel] [PATCH 7/7] avcodec/mjpegenc: Remove ineffective pred option Andreas Rheinhardt
  5 siblings, 0 replies; 8+ messages in thread
From: Andreas Rheinhardt @ 2022-05-16 18:38 UTC (permalink / raw)
  To: ffmpeg-devel; +Cc: Andreas Rheinhardt

(M)JPEG does not use motion estimation/motion vectors at all.
These options therefore don't affect the output at all.
So remove them.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
---
 libavcodec/ituh263enc.c    |  2 ++
 libavcodec/mpeg12enc.c     |  2 ++
 libavcodec/mpeg4videoenc.c |  1 +
 libavcodec/mpegvideo_enc.c |  1 +
 libavcodec/mpegvideoenc.h  | 16 +++++++++-------
 libavcodec/version.h       |  2 +-
 6 files changed, 16 insertions(+), 8 deletions(-)

diff --git a/libavcodec/ituh263enc.c b/libavcodec/ituh263enc.c
index e99ebfe076..ca44819639 100644
--- a/libavcodec/ituh263enc.c
+++ b/libavcodec/ituh263enc.c
@@ -885,6 +885,7 @@ static const AVOption h263_options[] = {
     { "obmc",         "use overlapped block motion compensation.", OFFSET(obmc), AV_OPT_TYPE_BOOL, { .i64 = 0 }, 0, 1, VE },
     { "mb_info",      "emit macroblock info for RFC 2190 packetization, the parameter value is the maximum payload size", OFFSET(mb_info), AV_OPT_TYPE_INT, { .i64 = 0 }, 0, INT_MAX, VE },
     FF_MPV_COMMON_OPTS
+    FF_MPV_COMMON_MOTION_EST_OPTS
 #if FF_API_MPEGVIDEO_OPTS
     FF_MPV_DEPRECATED_MPEG_QUANT_OPT
     FF_MPV_DEPRECATED_A53_CC_OPT
@@ -921,6 +922,7 @@ static const AVOption h263p_options[] = {
     { "obmc",       "use overlapped block motion compensation.", OFFSET(obmc), AV_OPT_TYPE_BOOL, { .i64 = 0 }, 0, 1, VE },
     { "structured_slices", "Write slice start position at every GOB header instead of just GOB number.", OFFSET(h263_slice_structured), AV_OPT_TYPE_BOOL, { .i64 = 0 }, 0, 1, VE},
     FF_MPV_COMMON_OPTS
+    FF_MPV_COMMON_MOTION_EST_OPTS
 #if FF_API_MPEGVIDEO_OPTS
     FF_MPV_DEPRECATED_MPEG_QUANT_OPT
     FF_MPV_DEPRECATED_A53_CC_OPT
diff --git a/libavcodec/mpeg12enc.c b/libavcodec/mpeg12enc.c
index 8d867cd7d0..e4980240c5 100644
--- a/libavcodec/mpeg12enc.c
+++ b/libavcodec/mpeg12enc.c
@@ -1172,6 +1172,7 @@ av_cold void ff_mpeg1_encode_init(MpegEncContext *s)
 static const AVOption mpeg1_options[] = {
     COMMON_OPTS
     FF_MPV_COMMON_OPTS
+    FF_MPV_COMMON_MOTION_EST_OPTS
 #if FF_API_MPEGVIDEO_OPTS
     FF_MPV_DEPRECATED_MPEG_QUANT_OPT
     FF_MPV_DEPRECATED_A53_CC_OPT
@@ -1205,6 +1206,7 @@ static const AVOption mpeg2_options[] = {
     { LEVEL("low",     10) },
 #undef LEVEL
     FF_MPV_COMMON_OPTS
+    FF_MPV_COMMON_MOTION_EST_OPTS
 #if FF_API_MPEGVIDEO_OPTS
     { "mpeg_quant",       "Deprecated, does nothing", FF_MPV_OFFSET(mpeg_quant),
       AV_OPT_TYPE_INT, {.i64 = 1 }, 0, 1, VE | AV_OPT_FLAG_DEPRECATED },
diff --git a/libavcodec/mpeg4videoenc.c b/libavcodec/mpeg4videoenc.c
index 69770dc153..45bba455bf 100644
--- a/libavcodec/mpeg4videoenc.c
+++ b/libavcodec/mpeg4videoenc.c
@@ -1379,6 +1379,7 @@ static const AVOption options[] = {
       OFFSET(mpeg_quant), AV_OPT_TYPE_INT, {.i64 = 0 }, 0, 1, VE },
     FF_MPV_COMMON_BFRAME_OPTS
     FF_MPV_COMMON_OPTS
+    FF_MPV_COMMON_MOTION_EST_OPTS
 #if FF_API_MPEGVIDEO_OPTS
     FF_MPV_DEPRECATED_A53_CC_OPT
     FF_MPV_DEPRECATED_MATRIX_OPT
diff --git a/libavcodec/mpegvideo_enc.c b/libavcodec/mpegvideo_enc.c
index c9d8c48026..1ef3e6f4a2 100644
--- a/libavcodec/mpegvideo_enc.c
+++ b/libavcodec/mpegvideo_enc.c
@@ -94,6 +94,7 @@ static uint8_t default_fcode_tab[MAX_MV * 2 + 1];
 
 static const AVOption mpv_generic_options[] = {
     FF_MPV_COMMON_OPTS
+    FF_MPV_COMMON_MOTION_EST_OPTS
 #if FF_API_MPEGVIDEO_OPTS
     FF_MPV_DEPRECATED_MPEG_QUANT_OPT
     FF_MPV_DEPRECATED_A53_CC_OPT
diff --git a/libavcodec/mpegvideoenc.h b/libavcodec/mpegvideoenc.h
index ecc389a6d3..a5f1014b50 100644
--- a/libavcodec/mpegvideoenc.h
+++ b/libavcodec/mpegvideoenc.h
@@ -92,10 +92,6 @@ FF_MPV_OPT_CMP_FUNC, \
 {"border_mask", "increase the quantizer for macroblocks close to borders", FF_MPV_OFFSET(border_masking), AV_OPT_TYPE_FLOAT, {.dbl = 0 }, -FLT_MAX, FLT_MAX, FF_MPV_OPT_FLAGS},    \
 {"lmin", "minimum Lagrange factor (VBR)",                           FF_MPV_OFFSET(lmin), AV_OPT_TYPE_INT, {.i64 =  2*FF_QP2LAMBDA }, 0, INT_MAX, FF_MPV_OPT_FLAGS },            \
 {"lmax", "maximum Lagrange factor (VBR)",                           FF_MPV_OFFSET(lmax), AV_OPT_TYPE_INT, {.i64 = 31*FF_QP2LAMBDA }, 0, INT_MAX, FF_MPV_OPT_FLAGS },            \
-{"motion_est", "motion estimation algorithm",                       FF_MPV_OFFSET(motion_est), AV_OPT_TYPE_INT, {.i64 = FF_ME_EPZS }, FF_ME_ZERO, FF_ME_XONE, FF_MPV_OPT_FLAGS, "motion_est" },   \
-{ "zero", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = FF_ME_ZERO }, 0, 0, FF_MPV_OPT_FLAGS, "motion_est" }, \
-{ "epzs", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = FF_ME_EPZS }, 0, 0, FF_MPV_OPT_FLAGS, "motion_est" }, \
-{ "xone", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = FF_ME_XONE }, 0, 0, FF_MPV_OPT_FLAGS, "motion_est" }, \
 {"skip_threshold", "Frame skip threshold",                          FF_MPV_OFFSET(frame_skip_threshold), AV_OPT_TYPE_INT, {.i64 = 0 }, INT_MIN, INT_MAX, FF_MPV_OPT_FLAGS }, \
 {"skip_factor", "Frame skip factor",                                FF_MPV_OFFSET(frame_skip_factor), AV_OPT_TYPE_INT, {.i64 = 0 }, INT_MIN, INT_MAX, FF_MPV_OPT_FLAGS }, \
 {"skip_exp", "Frame skip exponent",                                 FF_MPV_OFFSET(frame_skip_exp), AV_OPT_TYPE_INT, {.i64 = 0 }, INT_MIN, INT_MAX, FF_MPV_OPT_FLAGS }, \
@@ -103,15 +99,21 @@ FF_MPV_OPT_CMP_FUNC, \
 {"sc_threshold", "Scene change threshold",                          FF_MPV_OFFSET(scenechange_threshold), AV_OPT_TYPE_INT, {.i64 = 0 }, INT_MIN, INT_MAX, FF_MPV_OPT_FLAGS }, \
 {"noise_reduction", "Noise reduction",                              FF_MPV_OFFSET(noise_reduction), AV_OPT_TYPE_INT, {.i64 = 0 }, INT_MIN, INT_MAX, FF_MPV_OPT_FLAGS }, \
 {"ps", "RTP payload size in bytes",                             FF_MPV_OFFSET(rtp_payload_size), AV_OPT_TYPE_INT, {.i64 = 0 }, INT_MIN, INT_MAX, FF_MPV_OPT_FLAGS }, \
-{"mepc", "Motion estimation bitrate penalty compensation (1.0 = 256)", FF_MPV_OFFSET(me_penalty_compensation), AV_OPT_TYPE_INT, {.i64 = 256 }, INT_MIN, INT_MAX, FF_MPV_OPT_FLAGS }, \
-{"mepre", "pre motion estimation", FF_MPV_OFFSET(me_pre), AV_OPT_TYPE_INT, {.i64 = 0 }, INT_MIN, INT_MAX, FF_MPV_OPT_FLAGS }, \
-{"intra_penalty", "Penalty for intra blocks in block decision", FF_MPV_OFFSET(intra_penalty), AV_OPT_TYPE_INT, {.i64 = 0 }, 0, INT_MAX/2, FF_MPV_OPT_FLAGS }, \
 
 #define FF_MPV_COMMON_BFRAME_OPTS \
 {"b_strategy", "Strategy to choose between I/P/B-frames",      FF_MPV_OFFSET(b_frame_strategy), AV_OPT_TYPE_INT, {.i64 = 0 }, 0, 2, FF_MPV_OPT_FLAGS }, \
 {"b_sensitivity", "Adjust sensitivity of b_frame_strategy 1",  FF_MPV_OFFSET(b_sensitivity), AV_OPT_TYPE_INT, {.i64 = 40 }, 1, INT_MAX, FF_MPV_OPT_FLAGS }, \
 {"brd_scale", "Downscale frames for dynamic B-frame decision", FF_MPV_OFFSET(brd_scale), AV_OPT_TYPE_INT, {.i64 = 0 }, 0, 3, FF_MPV_OPT_FLAGS },
 
+#define FF_MPV_COMMON_MOTION_EST_OPTS \
+{"motion_est", "motion estimation algorithm",                       FF_MPV_OFFSET(motion_est), AV_OPT_TYPE_INT, {.i64 = FF_ME_EPZS }, FF_ME_ZERO, FF_ME_XONE, FF_MPV_OPT_FLAGS, "motion_est" },   \
+{ "zero", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = FF_ME_ZERO }, 0, 0, FF_MPV_OPT_FLAGS, "motion_est" }, \
+{ "epzs", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = FF_ME_EPZS }, 0, 0, FF_MPV_OPT_FLAGS, "motion_est" }, \
+{ "xone", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = FF_ME_XONE }, 0, 0, FF_MPV_OPT_FLAGS, "motion_est" }, \
+{"mepc", "Motion estimation bitrate penalty compensation (1.0 = 256)", FF_MPV_OFFSET(me_penalty_compensation), AV_OPT_TYPE_INT, {.i64 = 256 }, INT_MIN, INT_MAX, FF_MPV_OPT_FLAGS }, \
+{"mepre", "pre motion estimation", FF_MPV_OFFSET(me_pre), AV_OPT_TYPE_INT, {.i64 = 0 }, INT_MIN, INT_MAX, FF_MPV_OPT_FLAGS }, \
+{"intra_penalty", "Penalty for intra blocks in block decision", FF_MPV_OFFSET(intra_penalty), AV_OPT_TYPE_INT, {.i64 = 0 }, 0, INT_MAX/2, FF_MPV_OPT_FLAGS }, \
+
 #if FF_API_MPEGVIDEO_OPTS
 #define FF_MPV_DEPRECATED_MPEG_QUANT_OPT \
     { "mpeg_quant", "Deprecated, does nothing", FF_MPV_OFFSET(mpeg_quant), AV_OPT_TYPE_INT, {.i64 = 0 }, 0, 0, FF_MPV_OPT_FLAGS | AV_OPT_FLAG_DEPRECATED },
diff --git a/libavcodec/version.h b/libavcodec/version.h
index 5183deb68b..aeb58e3fed 100644
--- a/libavcodec/version.h
+++ b/libavcodec/version.h
@@ -29,7 +29,7 @@
 
 #include "version_major.h"
 
-#define LIBAVCODEC_VERSION_MINOR  29
+#define LIBAVCODEC_VERSION_MINOR  30
 #define LIBAVCODEC_VERSION_MICRO 100
 
 #define LIBAVCODEC_VERSION_INT  AV_VERSION_INT(LIBAVCODEC_VERSION_MAJOR, \
-- 
2.32.0

_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [FFmpeg-devel] [PATCH 6/7] avcodec/mpegvideoenc: Remove ineffective options
  2022-05-16 18:36 [FFmpeg-devel] [PATCH 1/7] avcodec/error_resilience: Only keep what is needed from MECmpContext Andreas Rheinhardt
                   ` (3 preceding siblings ...)
  2022-05-16 18:38 ` [FFmpeg-devel] [PATCH 5/7] avcodec/mjpegenc: Remove pointless motion-estimation options Andreas Rheinhardt
@ 2022-05-16 18:38 ` Andreas Rheinhardt
  2022-05-16 18:39 ` [FFmpeg-devel] [PATCH 7/7] avcodec/mjpegenc: Remove ineffective pred option Andreas Rheinhardt
  5 siblings, 0 replies; 8+ messages in thread
From: Andreas Rheinhardt @ 2022-05-16 18:38 UTC (permalink / raw)
  To: ffmpeg-devel; +Cc: Andreas Rheinhardt

This commit removes the ineffective FF_MPV_DEPRECATED_ options,
namely mpeg_quant (this is only an option for MPEG-4), a53cc
(this is only an option for MPEG-2), force_duplicated_matrix
(applies only to MJPEG) and b_strategy, b_sensitivity and brd_scale
(these options only make sense for encoders supporting B-frames,
which currently means the MPEG-1/2 and MPEG-4 encoders).
Given that these options never changed the outcome of encoding,
they are removed at once.

Notice that the options for the encoders for which it made sense
are not affected by this.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
---
 libavcodec/ituh263enc.c    | 12 ------------
 libavcodec/mjpegenc.c      |  5 -----
 libavcodec/mpeg12enc.c     | 11 +----------
 libavcodec/mpeg4videoenc.c |  4 ----
 libavcodec/mpegvideo.h     |  2 +-
 libavcodec/mpegvideo_enc.c |  6 ------
 libavcodec/mpegvideoenc.h  | 13 -------------
 libavcodec/version.h       |  2 +-
 libavcodec/version_major.h |  1 -
 9 files changed, 3 insertions(+), 53 deletions(-)

diff --git a/libavcodec/ituh263enc.c b/libavcodec/ituh263enc.c
index ca44819639..2fcd001dba 100644
--- a/libavcodec/ituh263enc.c
+++ b/libavcodec/ituh263enc.c
@@ -886,12 +886,6 @@ static const AVOption h263_options[] = {
     { "mb_info",      "emit macroblock info for RFC 2190 packetization, the parameter value is the maximum payload size", OFFSET(mb_info), AV_OPT_TYPE_INT, { .i64 = 0 }, 0, INT_MAX, VE },
     FF_MPV_COMMON_OPTS
     FF_MPV_COMMON_MOTION_EST_OPTS
-#if FF_API_MPEGVIDEO_OPTS
-    FF_MPV_DEPRECATED_MPEG_QUANT_OPT
-    FF_MPV_DEPRECATED_A53_CC_OPT
-    FF_MPV_DEPRECATED_MATRIX_OPT
-    FF_MPV_DEPRECATED_BFRAME_OPTS
-#endif
     { NULL },
 };
 
@@ -923,12 +917,6 @@ static const AVOption h263p_options[] = {
     { "structured_slices", "Write slice start position at every GOB header instead of just GOB number.", OFFSET(h263_slice_structured), AV_OPT_TYPE_BOOL, { .i64 = 0 }, 0, 1, VE},
     FF_MPV_COMMON_OPTS
     FF_MPV_COMMON_MOTION_EST_OPTS
-#if FF_API_MPEGVIDEO_OPTS
-    FF_MPV_DEPRECATED_MPEG_QUANT_OPT
-    FF_MPV_DEPRECATED_A53_CC_OPT
-    FF_MPV_DEPRECATED_MATRIX_OPT
-    FF_MPV_DEPRECATED_BFRAME_OPTS
-#endif
     { NULL },
 };
 static const AVClass h263p_class = {
diff --git a/libavcodec/mjpegenc.c b/libavcodec/mjpegenc.c
index 8cada8366c..0ba166da5d 100644
--- a/libavcodec/mjpegenc.c
+++ b/libavcodec/mjpegenc.c
@@ -637,11 +637,6 @@ FF_MPV_COMMON_OPTS
     { "default", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = HUFFMAN_TABLE_DEFAULT }, INT_MIN, INT_MAX, VE, "huffman" },
     { "optimal", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = HUFFMAN_TABLE_OPTIMAL }, INT_MIN, INT_MAX, VE, "huffman" },
 { "force_duplicated_matrix", "Always write luma and chroma matrix for mjpeg, useful for rtp streaming.", OFFSET(force_duplicated_matrix), AV_OPT_TYPE_BOOL, {.i64 = 0 }, 0, 1, VE },
-#if FF_API_MPEGVIDEO_OPTS
-FF_MPV_DEPRECATED_MPEG_QUANT_OPT
-FF_MPV_DEPRECATED_A53_CC_OPT
-FF_MPV_DEPRECATED_BFRAME_OPTS
-#endif
 { NULL},
 };
 
diff --git a/libavcodec/mpeg12enc.c b/libavcodec/mpeg12enc.c
index e4980240c5..09d63ff7dc 100644
--- a/libavcodec/mpeg12enc.c
+++ b/libavcodec/mpeg12enc.c
@@ -1142,6 +1142,7 @@ av_cold void ff_mpeg1_encode_init(MpegEncContext *s)
     } else {
         s->min_qcoeff = -2047;
         s->max_qcoeff = 2047;
+        s->mpeg_quant = 1;
     }
     if (s->intra_vlc_format) {
         s->intra_ac_vlc_length      =
@@ -1173,11 +1174,6 @@ static const AVOption mpeg1_options[] = {
     COMMON_OPTS
     FF_MPV_COMMON_OPTS
     FF_MPV_COMMON_MOTION_EST_OPTS
-#if FF_API_MPEGVIDEO_OPTS
-    FF_MPV_DEPRECATED_MPEG_QUANT_OPT
-    FF_MPV_DEPRECATED_A53_CC_OPT
-    FF_MPV_DEPRECATED_MATRIX_OPT
-#endif
     { NULL },
 };
 
@@ -1207,11 +1203,6 @@ static const AVOption mpeg2_options[] = {
 #undef LEVEL
     FF_MPV_COMMON_OPTS
     FF_MPV_COMMON_MOTION_EST_OPTS
-#if FF_API_MPEGVIDEO_OPTS
-    { "mpeg_quant",       "Deprecated, does nothing", FF_MPV_OFFSET(mpeg_quant),
-      AV_OPT_TYPE_INT, {.i64 = 1 }, 0, 1, VE | AV_OPT_FLAG_DEPRECATED },
-    FF_MPV_DEPRECATED_MATRIX_OPT
-#endif
     FF_MPEG2_PROFILE_OPTS
     { NULL },
 };
diff --git a/libavcodec/mpeg4videoenc.c b/libavcodec/mpeg4videoenc.c
index 45bba455bf..8f0452de3a 100644
--- a/libavcodec/mpeg4videoenc.c
+++ b/libavcodec/mpeg4videoenc.c
@@ -1380,10 +1380,6 @@ static const AVOption options[] = {
     FF_MPV_COMMON_BFRAME_OPTS
     FF_MPV_COMMON_OPTS
     FF_MPV_COMMON_MOTION_EST_OPTS
-#if FF_API_MPEGVIDEO_OPTS
-    FF_MPV_DEPRECATED_A53_CC_OPT
-    FF_MPV_DEPRECATED_MATRIX_OPT
-#endif
     FF_MPEG4_PROFILE_OPTS
     { NULL },
 };
diff --git a/libavcodec/mpegvideo.h b/libavcodec/mpegvideo.h
index a832369f7f..4b07c5bfb2 100644
--- a/libavcodec/mpegvideo.h
+++ b/libavcodec/mpegvideo.h
@@ -537,7 +537,7 @@ typedef struct MpegEncContext {
 
     int intra_penalty;
 
-#if FF_API_MPEGVIDEO_OPTS || FF_API_MJPEG_PRED
+#if FF_API_MJPEG_PRED
     int dummy;               ///< used as target for deprecated options
 #endif
 } MpegEncContext;
diff --git a/libavcodec/mpegvideo_enc.c b/libavcodec/mpegvideo_enc.c
index 1ef3e6f4a2..459bb3989f 100644
--- a/libavcodec/mpegvideo_enc.c
+++ b/libavcodec/mpegvideo_enc.c
@@ -95,12 +95,6 @@ static uint8_t default_fcode_tab[MAX_MV * 2 + 1];
 static const AVOption mpv_generic_options[] = {
     FF_MPV_COMMON_OPTS
     FF_MPV_COMMON_MOTION_EST_OPTS
-#if FF_API_MPEGVIDEO_OPTS
-    FF_MPV_DEPRECATED_MPEG_QUANT_OPT
-    FF_MPV_DEPRECATED_A53_CC_OPT
-    FF_MPV_DEPRECATED_MATRIX_OPT
-    FF_MPV_DEPRECATED_BFRAME_OPTS
-#endif
     { NULL },
 };
 
diff --git a/libavcodec/mpegvideoenc.h b/libavcodec/mpegvideoenc.h
index a5f1014b50..0e93124cc2 100644
--- a/libavcodec/mpegvideoenc.h
+++ b/libavcodec/mpegvideoenc.h
@@ -114,19 +114,6 @@ FF_MPV_OPT_CMP_FUNC, \
 {"mepre", "pre motion estimation", FF_MPV_OFFSET(me_pre), AV_OPT_TYPE_INT, {.i64 = 0 }, INT_MIN, INT_MAX, FF_MPV_OPT_FLAGS }, \
 {"intra_penalty", "Penalty for intra blocks in block decision", FF_MPV_OFFSET(intra_penalty), AV_OPT_TYPE_INT, {.i64 = 0 }, 0, INT_MAX/2, FF_MPV_OPT_FLAGS }, \
 
-#if FF_API_MPEGVIDEO_OPTS
-#define FF_MPV_DEPRECATED_MPEG_QUANT_OPT \
-    { "mpeg_quant", "Deprecated, does nothing", FF_MPV_OFFSET(mpeg_quant), AV_OPT_TYPE_INT, {.i64 = 0 }, 0, 0, FF_MPV_OPT_FLAGS | AV_OPT_FLAG_DEPRECATED },
-#define FF_MPV_DEPRECATED_A53_CC_OPT \
-    { "a53cc",      "Deprecated, does nothing", FF_MPV_OFFSET(dummy),      AV_OPT_TYPE_BOOL, { .i64 = 1 }, 0, 1, FF_MPV_OPT_FLAGS | AV_OPT_FLAG_DEPRECATED },
-#define FF_MPV_DEPRECATED_MATRIX_OPT \
-   { "force_duplicated_matrix", "Deprecated, does nothing", FF_MPV_OFFSET(dummy), AV_OPT_TYPE_BOOL, {.i64 = 0 }, 0, 1, FF_MPV_OPT_FLAGS | AV_OPT_FLAG_DEPRECATED },
-#define FF_MPV_DEPRECATED_BFRAME_OPTS \
-   { "b_strategy",    "Deprecated, does nothing", FF_MPV_OFFSET(b_frame_strategy), AV_OPT_TYPE_INT, { .i64 =  0 }, 0, 2, FF_MPV_OPT_FLAGS | AV_OPT_FLAG_DEPRECATED }, \
-   { "b_sensitivity", "Deprecated, does nothing", FF_MPV_OFFSET(b_sensitivity),    AV_OPT_TYPE_INT, { .i64 = 40 }, 1, INT_MAX, FF_MPV_OPT_FLAGS | AV_OPT_FLAG_DEPRECATED }, \
-   { "brd_scale",     "Deprecated, does nothing", FF_MPV_OFFSET(brd_scale),        AV_OPT_TYPE_INT, { .i64 =  0 }, 0, 3, FF_MPV_OPT_FLAGS | AV_OPT_FLAG_DEPRECATED },
-#endif
-
 extern const AVClass ff_mpv_enc_class;
 
 int ff_mpv_encode_init(AVCodecContext *avctx);
diff --git a/libavcodec/version.h b/libavcodec/version.h
index aeb58e3fed..497389d3f3 100644
--- a/libavcodec/version.h
+++ b/libavcodec/version.h
@@ -29,7 +29,7 @@
 
 #include "version_major.h"
 
-#define LIBAVCODEC_VERSION_MINOR  30
+#define LIBAVCODEC_VERSION_MINOR  31
 #define LIBAVCODEC_VERSION_MICRO 100
 
 #define LIBAVCODEC_VERSION_INT  AV_VERSION_INT(LIBAVCODEC_VERSION_MAJOR, \
diff --git a/libavcodec/version_major.h b/libavcodec/version_major.h
index 6ece4ac518..87609d5436 100644
--- a/libavcodec/version_major.h
+++ b/libavcodec/version_major.h
@@ -46,7 +46,6 @@
 #define FF_API_AUTO_THREADS        (LIBAVCODEC_VERSION_MAJOR < 60)
 #define FF_API_INIT_PACKET         (LIBAVCODEC_VERSION_MAJOR < 60)
 #define FF_API_AVCTX_TIMEBASE    (LIBAVCODEC_VERSION_MAJOR < 60)
-#define FF_API_MPEGVIDEO_OPTS      (LIBAVCODEC_VERSION_MAJOR < 60)
 #define FF_API_FLAG_TRUNCATED      (LIBAVCODEC_VERSION_MAJOR < 60)
 #define FF_API_SUB_TEXT_FORMAT     (LIBAVCODEC_VERSION_MAJOR < 60)
 #define FF_API_MJPEG_PRED          (LIBAVCODEC_VERSION_MAJOR < 60)
-- 
2.32.0

_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [FFmpeg-devel] [PATCH 7/7] avcodec/mjpegenc: Remove ineffective pred option
  2022-05-16 18:36 [FFmpeg-devel] [PATCH 1/7] avcodec/error_resilience: Only keep what is needed from MECmpContext Andreas Rheinhardt
                   ` (4 preceding siblings ...)
  2022-05-16 18:38 ` [FFmpeg-devel] [PATCH 6/7] avcodec/mpegvideoenc: Remove ineffective options Andreas Rheinhardt
@ 2022-05-16 18:39 ` Andreas Rheinhardt
  5 siblings, 0 replies; 8+ messages in thread
From: Andreas Rheinhardt @ 2022-05-16 18:39 UTC (permalink / raw)
  To: ffmpeg-devel; +Cc: Andreas Rheinhardt

Never did anything, so it is removed immediately.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
---
 libavcodec/mjpegenc.c      | 6 ------
 libavcodec/mpegvideo.h     | 4 ----
 libavcodec/version.h       | 2 +-
 libavcodec/version_major.h | 1 -
 4 files changed, 1 insertion(+), 12 deletions(-)

diff --git a/libavcodec/mjpegenc.c b/libavcodec/mjpegenc.c
index 0ba166da5d..27217441a3 100644
--- a/libavcodec/mjpegenc.c
+++ b/libavcodec/mjpegenc.c
@@ -627,12 +627,6 @@ static int amv_encode_picture(AVCodecContext *avctx, AVPacket *pkt,
 #define VE AV_OPT_FLAG_VIDEO_PARAM | AV_OPT_FLAG_ENCODING_PARAM
 static const AVOption options[] = {
 FF_MPV_COMMON_OPTS
-#if FF_API_MJPEG_PRED
-{ "pred", "Deprecated, does nothing", FF_MPV_OFFSET(dummy), AV_OPT_TYPE_INT, { .i64 = 1 }, 1, 3, VE, "pred" },
-    { "left",   NULL, 0, AV_OPT_TYPE_CONST, { .i64 = 1 }, INT_MIN, INT_MAX, VE, "pred" },
-    { "plane",  NULL, 0, AV_OPT_TYPE_CONST, { .i64 = 2 }, INT_MIN, INT_MAX, VE, "pred" },
-    { "median", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = 3 }, INT_MIN, INT_MAX, VE, "pred" },
-#endif
 { "huffman", "Huffman table strategy", OFFSET(huffman), AV_OPT_TYPE_INT, { .i64 = HUFFMAN_TABLE_OPTIMAL }, 0, NB_HUFFMAN_TABLE_OPTION - 1, VE, "huffman" },
     { "default", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = HUFFMAN_TABLE_DEFAULT }, INT_MIN, INT_MAX, VE, "huffman" },
     { "optimal", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = HUFFMAN_TABLE_OPTIMAL }, INT_MIN, INT_MAX, VE, "huffman" },
diff --git a/libavcodec/mpegvideo.h b/libavcodec/mpegvideo.h
index 4b07c5bfb2..82889a0edd 100644
--- a/libavcodec/mpegvideo.h
+++ b/libavcodec/mpegvideo.h
@@ -536,10 +536,6 @@ typedef struct MpegEncContext {
     int noise_reduction;
 
     int intra_penalty;
-
-#if FF_API_MJPEG_PRED
-    int dummy;               ///< used as target for deprecated options
-#endif
 } MpegEncContext;
 
 
diff --git a/libavcodec/version.h b/libavcodec/version.h
index 497389d3f3..56dbb9238d 100644
--- a/libavcodec/version.h
+++ b/libavcodec/version.h
@@ -29,7 +29,7 @@
 
 #include "version_major.h"
 
-#define LIBAVCODEC_VERSION_MINOR  31
+#define LIBAVCODEC_VERSION_MINOR  32
 #define LIBAVCODEC_VERSION_MICRO 100
 
 #define LIBAVCODEC_VERSION_INT  AV_VERSION_INT(LIBAVCODEC_VERSION_MAJOR, \
diff --git a/libavcodec/version_major.h b/libavcodec/version_major.h
index 87609d5436..1e23ed5e03 100644
--- a/libavcodec/version_major.h
+++ b/libavcodec/version_major.h
@@ -48,7 +48,6 @@
 #define FF_API_AVCTX_TIMEBASE    (LIBAVCODEC_VERSION_MAJOR < 60)
 #define FF_API_FLAG_TRUNCATED      (LIBAVCODEC_VERSION_MAJOR < 60)
 #define FF_API_SUB_TEXT_FORMAT     (LIBAVCODEC_VERSION_MAJOR < 60)
-#define FF_API_MJPEG_PRED          (LIBAVCODEC_VERSION_MAJOR < 60)
 #define FF_API_IDCT_NONE           (LIBAVCODEC_VERSION_MAJOR < 60)
 #define FF_API_SVTAV1_OPTS         (LIBAVCODEC_VERSION_MAJOR < 60)
 
-- 
2.32.0

_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [FFmpeg-devel] [PATCH 4/7] avcodec/mpegvideoenc: Remove ineffective [pb]bias options
  2022-05-16 18:38 ` [FFmpeg-devel] [PATCH 4/7] avcodec/mpegvideoenc: Remove ineffective [pb]bias options Andreas Rheinhardt
@ 2022-05-19 18:16   ` Andreas Rheinhardt
  0 siblings, 0 replies; 8+ messages in thread
From: Andreas Rheinhardt @ 2022-05-19 18:16 UTC (permalink / raw)
  To: ffmpeg-devel

Andreas Rheinhardt:
> The user-provided value is overwritten in ff_mpv_encode_init()
> without having ever been read.
> (This has been broken when making these options mpegvideo-specific
> in commits 910247f1720c6aae422723c05dac6d0b19f20bec and
> cf7d2f2d2134c0854edf2db91e7436ac2bc9874f. No one has ever complained,
> so this commit removes these fields.)
> 
> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
> ---
>  libavcodec/mpegvideoenc.h | 4 ----
>  libavcodec/version.h      | 2 +-
>  2 files changed, 1 insertion(+), 5 deletions(-)
> 
> diff --git a/libavcodec/mpegvideoenc.h b/libavcodec/mpegvideoenc.h
> index a0e8913ea6..ecc389a6d3 100644
> --- a/libavcodec/mpegvideoenc.h
> +++ b/libavcodec/mpegvideoenc.h
> @@ -43,8 +43,6 @@
>  #define FF_MPV_FLAG_NAQ          0x0010
>  #define FF_MPV_FLAG_MV0          0x0020
>  
> -#define FF_DEFAULT_QUANT_BIAS 999999
> -
>  #define FF_MPV_OPT_CMP_FUNC \
>  { "sad",    "Sum of absolute differences, fast", 0, AV_OPT_TYPE_CONST, {.i64 = FF_CMP_SAD }, INT_MIN, INT_MAX, FF_MPV_OPT_FLAGS, "cmp_func" }, \
>  { "sse",    "Sum of squared errors", 0, AV_OPT_TYPE_CONST, {.i64 = FF_CMP_SSE }, INT_MIN, INT_MAX, FF_MPV_OPT_FLAGS, "cmp_func" }, \
> @@ -94,8 +92,6 @@ FF_MPV_OPT_CMP_FUNC, \
>  {"border_mask", "increase the quantizer for macroblocks close to borders", FF_MPV_OFFSET(border_masking), AV_OPT_TYPE_FLOAT, {.dbl = 0 }, -FLT_MAX, FLT_MAX, FF_MPV_OPT_FLAGS},    \
>  {"lmin", "minimum Lagrange factor (VBR)",                           FF_MPV_OFFSET(lmin), AV_OPT_TYPE_INT, {.i64 =  2*FF_QP2LAMBDA }, 0, INT_MAX, FF_MPV_OPT_FLAGS },            \
>  {"lmax", "maximum Lagrange factor (VBR)",                           FF_MPV_OFFSET(lmax), AV_OPT_TYPE_INT, {.i64 = 31*FF_QP2LAMBDA }, 0, INT_MAX, FF_MPV_OPT_FLAGS },            \
> -{"ibias", "intra quant bias",                                       FF_MPV_OFFSET(intra_quant_bias), AV_OPT_TYPE_INT, {.i64 = FF_DEFAULT_QUANT_BIAS }, INT_MIN, INT_MAX, FF_MPV_OPT_FLAGS },   \
> -{"pbias", "inter quant bias",                                       FF_MPV_OFFSET(inter_quant_bias), AV_OPT_TYPE_INT, {.i64 = FF_DEFAULT_QUANT_BIAS }, INT_MIN, INT_MAX, FF_MPV_OPT_FLAGS },   \
>  {"motion_est", "motion estimation algorithm",                       FF_MPV_OFFSET(motion_est), AV_OPT_TYPE_INT, {.i64 = FF_ME_EPZS }, FF_ME_ZERO, FF_ME_XONE, FF_MPV_OPT_FLAGS, "motion_est" },   \
>  { "zero", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = FF_ME_ZERO }, 0, 0, FF_MPV_OPT_FLAGS, "motion_est" }, \
>  { "epzs", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = FF_ME_EPZS }, 0, 0, FF_MPV_OPT_FLAGS, "motion_est" }, \
> diff --git a/libavcodec/version.h b/libavcodec/version.h
> index 87b7284a95..5183deb68b 100644
> --- a/libavcodec/version.h
> +++ b/libavcodec/version.h
> @@ -29,7 +29,7 @@
>  
>  #include "version_major.h"
>  
> -#define LIBAVCODEC_VERSION_MINOR  28
> +#define LIBAVCODEC_VERSION_MINOR  29
>  #define LIBAVCODEC_VERSION_MICRO 100
>  
>  #define LIBAVCODEC_VERSION_INT  AV_VERSION_INT(LIBAVCODEC_VERSION_MAJOR, \

Ping for the last four patches of this patchset. I plan to push them on
Sunday unless there are objections.

- Andreas
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2022-05-19 18:16 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-05-16 18:36 [FFmpeg-devel] [PATCH 1/7] avcodec/error_resilience: Only keep what is needed from MECmpContext Andreas Rheinhardt
2022-05-16 18:38 ` [FFmpeg-devel] [PATCH 2/7] avcodec/mss2: Remove write-only QpelDSPContext Andreas Rheinhardt
2022-05-16 18:38 ` [FFmpeg-devel] [PATCH 3/7] avcodec/mpegvideo: Move float.h inclusion to mpegvideoenc.h Andreas Rheinhardt
2022-05-16 18:38 ` [FFmpeg-devel] [PATCH 4/7] avcodec/mpegvideoenc: Remove ineffective [pb]bias options Andreas Rheinhardt
2022-05-19 18:16   ` Andreas Rheinhardt
2022-05-16 18:38 ` [FFmpeg-devel] [PATCH 5/7] avcodec/mjpegenc: Remove pointless motion-estimation options Andreas Rheinhardt
2022-05-16 18:38 ` [FFmpeg-devel] [PATCH 6/7] avcodec/mpegvideoenc: Remove ineffective options Andreas Rheinhardt
2022-05-16 18:39 ` [FFmpeg-devel] [PATCH 7/7] avcodec/mjpegenc: Remove ineffective pred option Andreas Rheinhardt

Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

This inbox may be cloned and mirrored by anyone:

	git clone --mirror https://master.gitmailbox.com/ffmpegdev/0 ffmpegdev/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 ffmpegdev ffmpegdev/ https://master.gitmailbox.com/ffmpegdev \
		ffmpegdev@gitmailbox.com
	public-inbox-index ffmpegdev

Example config snippet for mirrors.


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git