[MPlayer-dev-eng] [PATCH] remove obsolete lavcopts mbqmin/max

Loren Merritt lorenm at u.washington.edu
Fri Sep 10 07:27:21 CEST 2004


The lavc options mbqmin and mbqmax have done nothing since Lagrange 
multipliers were introduced (2003-10-7). They were then replaced by
vqmin and vqmax.

--Loren Merritt
-------------- next part --------------
--- libmpcodecs/ve_lavc.c~	2004-08-21 12:31:00.000000000 -0700
+++ libmpcodecs/ve_lavc.c	2004-09-09 21:10:40.000000000 -0700
@@ -176,8 +176,10 @@
 	{"vqscale", &lavc_param_vqscale, CONF_TYPE_FLOAT, CONF_RANGE, 0.01, 255.0, NULL},
 	{"vqmin", &lavc_param_vqmin, CONF_TYPE_INT, CONF_RANGE, 1, 31, NULL},
 	{"vqmax", &lavc_param_vqmax, CONF_TYPE_INT, CONF_RANGE, 1, 31, NULL},
+#if LIBAVCODEC_BUILD <= 4683
 	{"mbqmin", &lavc_param_mb_qmin, CONF_TYPE_INT, CONF_RANGE, 1, 31, NULL},
 	{"mbqmax", &lavc_param_mb_qmax, CONF_TYPE_INT, CONF_RANGE, 1, 31, NULL},
+#endif
 	{"lmin", &lavc_param_lmin, CONF_TYPE_FLOAT, CONF_RANGE, 0.01, 255.0, NULL},
 	{"lmax", &lavc_param_lmax, CONF_TYPE_FLOAT, CONF_RANGE, 0.01, 255.0, NULL},
 	{"vqdiff", &lavc_param_vqdiff, CONF_TYPE_INT, CONF_RANGE, 1, 31, NULL},
@@ -353,7 +355,7 @@
 #endif
     lavc_venc_context->qmin= lavc_param_vqmin;
     lavc_venc_context->qmax= lavc_param_vqmax;
-#if LIBAVCODEC_BUILD >= 4646
+#if LIBAVCODEC_BUILD >= 4646 && LIBAVCODEC_BUILD <= 4683
     lavc_venc_context->mb_qmin= lavc_param_mb_qmin;
     lavc_venc_context->mb_qmax= lavc_param_mb_qmax;
 #endif
--- DOCS/man/de/mplayer.1~	2004-09-07 04:00:27.000000000 -0700
+++ DOCS/man/de/mplayer.1	2004-09-09 22:01:07.000000000 -0700
@@ -4017,10 +4017,6 @@
 (Standardwert: 0 (ausgeschaltet))
 .IPs vqmax=<1\-31>
 maximaler Quantizer (bei Durchgang 1/\:2) (Standardwert: 31)
-.IPs mbqmin=<1\-31>
-minimale Makroblock-Quantizer (bei Durchgang\ 1/\:2) (Standardwert: 2)
-.IPs mbqmax=<1\-31>
-maximale Makroblock-Quantizer (bei Durchgang\ 1/\:2) (Standardwert: 31)
 .IPs vqdiff=<1\-31>
 maximale Differenz der Quantizer zwischen I\- oder P\-Bildern (bei
 Durchgang 1/\:2) (Standardwert: 3)
--- DOCS/man/en/mplayer.1~	2004-09-09 05:53:30.000000000 -0700
+++ DOCS/man/en/mplayer.1	2004-09-09 21:57:56.000000000 -0700
@@ -5010,14 +5010,6 @@
 maximum quantizer (pass\ 1/\:2) 10\-31 should be a sane range (default: 31)
 .
 .TP
-.B mbqmin=<1\-31>
-minimum macroblock quantizer (pass\ 1/\:2) (default: 2)
-.
-.TP
-.B mbqmax=<1\-31>
-maximum macroblock quantizer (pass\ 1/\:2) (default: 31)
-.
-.TP
 .B vqdiff=<1\-31>
 maximum quantizer difference between I or P frames (pass\ 1/\:2) (default: 3)
 .
--- DOCS/man/es/mplayer.1~	2004-08-22 11:57:43.000000000 -0700
+++ DOCS/man/es/mplayer.1	2004-09-09 22:01:43.000000000 -0700
@@ -4761,12 +4761,6 @@
 cuantizador m?ximo (pasada\ 1/\:2) 10\-31 debe ser un rango aceptable
 (por defecto: 31)
 .TP
-.B mbqmin=<1\-31>
-cuantizador m?nimo de macrobloque (pasada\ 1/\:2) (por defecto: 2)
-.TP
-.B mbqmax=<1\-31>
-cuantizador m?ximo de macrobloque (pasada\ 1/\:2) (por defecto: 31)
-.TP
 .B vqdiff=<1\-31>
 m?xima diferencia del cuantizador entre marcos I o P (pasada\ 1/\:2) (por defecto: 3)
 .TP
--- DOCS/man/fr/mplayer.1~	2004-09-09 11:36:15.000000000 -0700
+++ DOCS/man/fr/mplayer.1	2004-09-09 22:01:58.000000000 -0700
@@ -5235,14 +5235,6 @@
 raisonable (par d?faut\ : 31)
 .
 .TP
-.B mbqmin=<1\-31>
-quantificateur minimum de macro-bloc (passe\ 1/\:2) (par d?faut\ : 2)
-.
-.TP
-.B mbqmax=<1\-31>
-quantificateur maximum de macro-bloc (passe\ 1/\:2) (par d?faut\ : 31)
-.
-.TP
 .B vqdiff=<1\-31>
 diff?rence maximale de quantificateur entre les trames I ou P (passe\ 1/\:2)
 (par d?faut\ : 3)
--- DOCS/man/hu/mplayer.1~	2004-08-22 11:57:44.000000000 -0700
+++ DOCS/man/hu/mplayer.1	2004-09-09 22:02:11.000000000 -0700
@@ -3053,10 +3053,6 @@
 constant quantizer (fix quantizeres m?d bekapcsol?sa) (alap: 0 (kikapcsolva))
 .IPs vqmax=<1\-31>
 maximum quantizer (1/\:2-es menet) (alap: 31)
-.IPs mbqmin=<1\-31>
-minimum macroblock quantizer (1/\:2-es menet) (alap: 2)
-.IPs mbqmax=<1\-31>
-maximum macroblock quantizer (1/\:2-es menet) (alap: 31)
 .IPs vqdiff=<1\-31>
 maximum quantizer k?l?nbs?g I vagy P k?pkock?k k?z?tt (1/\:2-es menet) (alap: 3)
 .IPs vmax_b_frames=<0\-4>
--- DOCS/man/it/mplayer.1~	2004-09-08 02:42:05.000000000 -0700
+++ DOCS/man/it/mplayer.1	2004-09-09 22:02:33.000000000 -0700
@@ -5269,14 +5269,6 @@
 buon valore (default: 31)
 .
 .TP
-.B mbqmin=<1\-31>
-valore minimo di quantizzazione del macroblock (passo\ 1/\:2) (default: 2)
-.
-.TP
-.B mbqmax=<1\-31>
-valore massimo di quantizzazione del macroblock (passo\ 1/\:2) (default: 31)
-.
-.TP
 .B vqdiff=<1\-31>
 valore massimo di differenza di quantizzazione tra fotogrammi I o P
 (passo\ 1/\:2) (default: 3) (??? differenza con cosa ???)
--- DOCS/man/pl/mplayer.1~	2004-09-09 05:22:27.000000000 -0700
+++ DOCS/man/pl/mplayer.1	2004-09-09 22:02:41.000000000 -0700
@@ -5062,14 +5062,6 @@
 (domy?lnie: 31)
 .
 .TP
-.B mbqmin=<1\-31>
-minimalny kwantyzator makrobloku (przej?cie\ 1/\:2) (domy?lnie: 2)
-.
-.TP
-.B mbqmax=<1\-31>
-maksymalny kwantyzator makrobloku (przej?cie\ 1/\:2) (domy?lnie: 31)
-.
-.TP
 .B vqdiff=<1\-31>
 maksymalna r??nica kwantyzatora mi?dzy ramkami I a P (przej?cie\ 1/\:2)
 (domy?lnie: 3)
--- DOCS/man/zh/mplayer.1~	2004-07-21 07:08:46.000000000 -0700
+++ DOCS/man/zh/mplayer.1	2004-09-09 22:03:18.000000000 -0700
@@ -2534,10 +2534,6 @@
 ??????????1(????????\-vqmin).
 .IPs vqmax=<1\-31>
 ??????????(pass\ 1/\:2), 10\-31??????????????(??????: 31)
-.IPs mbqmin=<1\-31>
-??????????????(pass\ 1/\:2)(??????: 2)
-.IPs mbqmax=<1\-31>
-??????????????(pass\ 1/\:2)(??????: 31)
 .IPs vqdiff=<1\-31>
 I??P????????????????(pass\ 1/\:2)(??????: 3)
 .IPs vmax_b_frames=<0\-4>
-------------- next part --------------
Index: ffmpeg.c
===================================================================
RCS file: /cvsroot/ffmpeg/ffmpeg/ffmpeg.c,v
retrieving revision 1.259
diff -u -r1.259 ffmpeg.c
--- ffmpeg.c	2 Sep 2004 13:28:37 -0000	1.259
+++ ffmpeg.c	10 Sep 2004 04:55:21 -0000
@@ -102,8 +102,6 @@
 static int video_qmax = 31;
 static int video_lmin = 2*FF_QP2LAMBDA;
 static int video_lmax = 31*FF_QP2LAMBDA;
-static int video_mb_qmin = 2;
-static int video_mb_qmax = 31;
 static int video_qdiff = 3;
 static float video_qblur = 0.5;
 static float video_qcomp = 0.5;
@@ -2426,26 +2424,6 @@
     }
 }
 
-static void opt_mb_qmin(const char *arg)
-{
-    video_mb_qmin = atoi(arg);
-    if (video_mb_qmin < 0 ||
-        video_mb_qmin > 31) {
-        fprintf(stderr, "qmin must be >= 1 and <= 31\n");
-        exit(1);
-    }
-}
-
-static void opt_mb_qmax(const char *arg)
-{
-    video_mb_qmax = atoi(arg);
-    if (video_mb_qmax < 0 ||
-        video_mb_qmax > 31) {
-        fprintf(stderr, "qmax must be >= 1 and <= 31\n");
-        exit(1);
-    }
-}
-
 static void opt_qdiff(const char *arg)
 {
     video_qdiff = atoi(arg);
@@ -3094,8 +3072,6 @@
                 video_enc->qmax = video_qmax;
                 video_enc->lmin = video_lmin;
                 video_enc->lmax = video_lmax;
-                video_enc->mb_qmin = video_mb_qmin;
-                video_enc->mb_qmax = video_mb_qmax;
                 video_enc->max_qdiff = video_qdiff;
                 video_enc->qblur = video_qblur;
                 video_enc->qcompress = video_qcomp;
@@ -3760,8 +3736,6 @@
     { "qmax", HAS_ARG | OPT_EXPERT | OPT_VIDEO, {(void*)opt_qmax}, "max video quantiser scale (VBR)", "q" },
     { "lmin", HAS_ARG | OPT_EXPERT | OPT_VIDEO, {(void*)opt_lmin}, "min video lagrange factor (VBR)", "lambda" },
     { "lmax", HAS_ARG | OPT_EXPERT | OPT_VIDEO, {(void*)opt_lmax}, "max video lagrange factor (VBR)", "lambda" },
-    { "mbqmin", HAS_ARG | OPT_EXPERT | OPT_VIDEO, {(void*)opt_mb_qmin}, "min macroblock quantiser scale (VBR)", "q" },
-    { "mbqmax", HAS_ARG | OPT_EXPERT | OPT_VIDEO, {(void*)opt_mb_qmax}, "max macroblock quantiser scale (VBR)", "q" },
     { "qdiff", HAS_ARG | OPT_EXPERT | OPT_VIDEO, {(void*)opt_qdiff}, "max difference between the quantiser scale (VBR)", "q" },
     { "qblur", HAS_ARG | OPT_EXPERT | OPT_VIDEO, {(void*)opt_qblur}, "video quantiser scale blur (VBR)", "blur" },
     { "qcomp", HAS_ARG | OPT_EXPERT | OPT_VIDEO, {(void*)opt_qcomp}, "video quantiser scale compression (VBR)", "compression" },
Index: libavcodec/avcodec.h
===================================================================
RCS file: /cvsroot/ffmpeg/ffmpeg/libavcodec/avcodec.h,v
retrieving revision 1.332
diff -u -r1.332 avcodec.h
--- libavcodec/avcodec.h	2 Sep 2004 15:30:45 -0000	1.332
+++ libavcodec/avcodec.h	10 Sep 2004 04:55:22 -0000
@@ -1217,14 +1217,14 @@
     
     /**
      * minimum MB quantizer.
-     * - encoding: set by user.
+     * - encoding: unused
      * - decoding: unused
      */
     int mb_qmin;
 
     /**
      * maximum MB quantizer.
-     * - encoding: set by user.
+     * - encoding: unused
      * - decoding: unused
      */
     int mb_qmax;
Index: libavcodec/mpegvideo.c
===================================================================
RCS file: /cvsroot/ffmpeg/ffmpeg/libavcodec/mpegvideo.c,v
retrieving revision 1.426
diff -u -r1.426 mpegvideo.c
--- libavcodec/mpegvideo.c	8 Sep 2004 10:07:08 -0000	1.426
+++ libavcodec/mpegvideo.c	10 Sep 2004 04:55:27 -0000
@@ -5961,11 +5961,6 @@
     AVOPTION_CODEC_INT("idct_algo", "idct alghorithm",
 		       idct_algo, 0, 8, 0), // fixme - "Auto,Int,Simple,SimpleMMX,LibMPEG2MMX,PS2,MLib,ARM,Altivec"
 
-    AVOPTION_CODEC_INT("mb_qmin", "minimum MB quantizer",
-		       mb_qmin, 0, 8, 0),
-    AVOPTION_CODEC_INT("mb_qmax", "maximum MB quantizer",
-		       mb_qmin, 0, 8, 0),
-
     AVOPTION_CODEC_INT("me_cmp", "ME compare function",
 		       me_cmp, 0, 24000000, 0),
     AVOPTION_CODEC_INT("me_sub_cmp", "subpixel ME compare function",


More information about the MPlayer-dev-eng mailing list