summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--DOCS/man/en/mplayer.123
-rwxr-xr-xconfigure2
-rw-r--r--libmpcodecs/ve_x264.c23
3 files changed, 37 insertions, 11 deletions
diff --git a/DOCS/man/en/mplayer.1 b/DOCS/man/en/mplayer.1
index 26a6e7a2fe..b64beee5c7 100644
--- a/DOCS/man/en/mplayer.1
+++ b/DOCS/man/en/mplayer.1
@@ -8079,17 +8079,28 @@ of the B-frame relative to the references.
Requires bframes > 1.
.
.TP
+.B (no)i4x4
+Use additional macroblock type i4x4 (default: enabled).
+Without this option, P- and B-frames will use only
+i16x16 and the inter types specified below.
+.
+.TP
+.B (no)i8x8
+Use additional macroblock type i8x8 (default: enabled).
+This option has no effect unless 8x8dct is enabled.
+.
+.TP
.B (no)b8x8mv
Use additional macroblock types b16x8, b8x16, b8x8 (default: enabled).
Without this option, B-frames will use only types
-i16x16, i4x4, b16x16, skip, direct.
+i16x16, i8x8, i4x4, b16x16, skip, direct.
See 4x4mv for details.
.
.TP
.B (no)8x8mv
Use additional macroblock types p16x8, p8x16, p8x8 (default: enabled).
Without this option, P-frames will use only types
-i16x16, i4x4, p16x16, skip.
+i16x16, i8x8, i4x4, p16x16, skip.
This option is provided for experimentation only.
It is not recommended to disable 8x8mv in a real encode.
.
@@ -8097,7 +8108,7 @@ It is not recommended to disable 8x8mv in a real encode.
.B (no)4x4mv
Use additional macroblock types p8x4, p4x8, p4x4 (default: disabled).
Without this option, P-frames will use only types
-i16x16, i4x4, p16x16, p16x8, p8x16, p8x8, skip.
+i16x16, i8x8, i4x4, p16x16, p16x8, p8x16, p8x8, skip.
Requires 8x8mv.
.br
The idea is to find the type and size that best describe a certain area
@@ -8108,6 +8119,12 @@ small moving objects are better represented by smaller blocks.
4x4mv is recommended only with subq >= 3.
.
.TP
+.B (no)8x8dct
+Adaptive spatial transform size: allows macroblocks to choose between
+4x4 and 8x8 DCT. Also allows the i8x8 macroblock type.
+Without this option, only 4x4 DCT is used.
+.
+.TP
.B me=<1\-4>
Select fullpixel motion estimation algorithm.
.PD 0
diff --git a/configure b/configure
index 0d1c5e6aa2..a87ffcefdb 100755
--- a/configure
+++ b/configure
@@ -6090,7 +6090,7 @@ echocheck "x264"
cat > $TMPC << EOF
#include <inttypes.h>
#include <x264.h>
-#if X264_BUILD < 28
+#if X264_BUILD < 29
#error We do not support old versions of x264. Get the latest from SVN.
#endif
int main(void) { x264_encoder_open((void*)0); return 0; }
diff --git a/libmpcodecs/ve_x264.c b/libmpcodecs/ve_x264.c
index bc027a0fec..5e411bcb23 100644
--- a/libmpcodecs/ve_x264.c
+++ b/libmpcodecs/ve_x264.c
@@ -75,6 +75,9 @@ static int cabac = 1;
static int p4x4mv = 0;
static int p8x8mv = 1;
static int b8x8mv = 1;
+static int i8x8 = 1;
+static int i4x4 = 1;
+static int dct8 = 0;
static int direct_pred = X264_DIRECT_PRED_TEMPORAL;
static int weight_b = 0;
static int chroma_me = 1;
@@ -127,6 +130,12 @@ m_option_t x264encopts_conf[] = {
{"no8x8mv", &p8x8mv, CONF_TYPE_FLAG, 0, 1, 0, NULL},
{"b8x8mv", &b8x8mv, CONF_TYPE_FLAG, 0, 0, 1, NULL},
{"nob8x8mv", &b8x8mv, CONF_TYPE_FLAG, 0, 1, 0, NULL},
+ {"i4x4", &i4x4, CONF_TYPE_FLAG, 0, 0, 1, NULL},
+ {"noi4x4", &i4x4, CONF_TYPE_FLAG, 0, 0, 0, NULL},
+ {"i8x8", &i8x8, CONF_TYPE_FLAG, 0, 0, 1, NULL},
+ {"noi8x8", &i8x8, CONF_TYPE_FLAG, 0, 0, 0, NULL},
+ {"8x8dct", &dct8, CONF_TYPE_FLAG, 0, 0, 1, NULL},
+ {"no8x8dct", &dct8, CONF_TYPE_FLAG, 0, 0, 0, NULL},
{"direct_pred", &direct_pred, CONF_TYPE_INT, CONF_RANGE, 0, 2, NULL},
{"weight_b", &weight_b, CONF_TYPE_FLAG, 0, 0, 1, NULL},
{"noweight_b", &weight_b, CONF_TYPE_FLAG, 0, 1, 0, NULL},
@@ -245,13 +254,13 @@ static int config(struct vf_instance_s* vf, int width, int height, int d_width,
}
if(me_method >= 3)
mod->param.analyse.i_me_range = me_range;
- mod->param.analyse.inter = X264_ANALYSE_I4x4;
- if(p4x4mv)
- mod->param.analyse.inter |= X264_ANALYSE_PSUB8x8;
- if(p8x8mv)
- mod->param.analyse.inter |= X264_ANALYSE_PSUB16x16;
- if(b8x8mv)
- mod->param.analyse.inter |= X264_ANALYSE_BSUB16x16;
+ mod->param.analyse.inter = 0;
+ if(p4x4mv) mod->param.analyse.inter |= X264_ANALYSE_PSUB8x8;
+ if(p8x8mv) mod->param.analyse.inter |= X264_ANALYSE_PSUB16x16;
+ if(b8x8mv) mod->param.analyse.inter |= X264_ANALYSE_BSUB16x16;
+ if(i4x4) mod->param.analyse.inter |= X264_ANALYSE_I4x4;
+ if(i8x8) mod->param.analyse.inter |= X264_ANALYSE_I8x8;
+ mod->param.analyse.b_transform_8x8 = dct8;
mod->param.analyse.i_direct_mv_pred = direct_pred;
mod->param.analyse.b_weighted_bipred = weight_b;
mod->param.analyse.i_chroma_qp_offset = chroma_qp_offset;