]> git.sesse.net Git - x264/blobdiff - x264.c
Add checkasm tests for memcpy_aligned, memzero_aligned
[x264] / x264.c
diff --git a/x264.c b/x264.c
index 2ab7f96099a8845040f00d440869c6c330ac867a..4d693d485ca9f801a8bbcec2abd4719da9ebe07f 100644 (file)
--- a/x264.c
+++ b/x264.c
@@ -269,6 +269,9 @@ int main( int argc, char **argv )
     if( parse( argc, argv, &param, &opt ) < 0 )
         ret = -1;
 
+    /* Restore title; it can be changed by input modules */
+    SetConsoleTitle( originalCTitle );
+
     /* Control-C handler */
     signal( SIGINT, sigint_handler );
 
@@ -328,11 +331,11 @@ static void print_csp_names( int longhelp )
     printf( "\n" );
     printf( "                              - valid csps for `lavf' demuxer:\n" );
     printf( INDENT );
-    int line_len = strlen( INDENT );
+    size_t line_len = strlen( INDENT );
     for( enum PixelFormat i = PIX_FMT_NONE+1; i < PIX_FMT_NB; i++ )
     {
         const char *pfname = av_pix_fmt_descriptors[i].name;
-        int name_len = strlen( pfname );
+        size_t name_len = strlen( pfname );
         if( line_len + name_len > (80 - strlen( ", " )) )
         {
             printf( "\n" INDENT );
@@ -538,11 +541,7 @@ static void help( x264_param_t *defaults, int longhelp )
         "                                  - strict: Strictly hierarchical pyramid\n"
         "                                  - normal: Non-strict (not Blu-ray compatible)\n",
         strtable_lookup( x264_b_pyramid_names, defaults->i_bframe_pyramid ) );
-    H1( "      --open-gop <string>     Use recovery points to close GOPs [none]\n"
-        "                                  - none: closed GOPs only\n"
-        "                                  - normal: standard open GOPs\n"
-        "                                            (not Blu-ray compatible)\n"
-        "                                  - bluray: Blu-ray-compatible open GOPs\n"
+    H1( "      --open-gop              Use recovery points to close GOPs\n"
         "                              Only available with b-frames\n" );
     H1( "      --no-cabac              Disable CABAC\n" );
     H1( "  -r, --ref <integer>         Number of reference frames [%d]\n", defaults->i_frame_reference );
@@ -738,6 +737,7 @@ static void help( x264_param_t *defaults, int longhelp )
     H0( "      --seek <integer>        First frame to encode\n" );
     H0( "      --frames <integer>      Maximum number of frames to encode\n" );
     H0( "      --level <string>        Specify level (as defined by Annex A)\n" );
+    H1( "      --bluray-compat         Enable compatibility hacks for Blu-ray support\n" );
     H1( "\n" );
     H1( "  -v, --verbose               Print stats for each frame\n" );
     H1( "      --no-progress           Don't show the progress indicator while encoding\n" );
@@ -828,7 +828,8 @@ static struct option long_options[] =
     { "no-b-adapt",        no_argument, NULL, 0 },
     { "b-bias",      required_argument, NULL, 0 },
     { "b-pyramid",   required_argument, NULL, 0 },
-    { "open-gop",    required_argument, NULL, 0 },
+    { "open-gop",          no_argument, NULL, 0 },
+    { "bluray-compat",     no_argument, NULL, 0 },
     { "min-keyint",  required_argument, NULL, 'i' },
     { "keyint",      required_argument, NULL, 'I' },
     { "intra-refresh",     no_argument, NULL, 0 },
@@ -1398,6 +1399,8 @@ generic_option:
     info.tff        = param->b_tff;
     info.vfr        = param->b_vfr_input;
 
+    input_opt.progress = opt->b_progress;
+
     if( select_input( demuxer, demuxername, input_filename, &opt->hin, &info, &input_opt ) )
         return -1;
 
@@ -1493,11 +1496,15 @@ generic_option:
 
     if( !b_user_interlaced && info.interlaced )
     {
+#if HAVE_INTERLACED
         x264_cli_log( "x264", X264_LOG_WARNING, "input appears to be interlaced, enabling %cff interlaced mode.\n"
                       "                If you want otherwise, use --no-interlaced or --%cff\n",
                       info.tff ? 't' : 'b', info.tff ? 'b' : 't' );
         param->b_interlaced = 1;
         param->b_tff = !!info.tff;
+#else
+        x264_cli_log( "x264", X264_LOG_WARNING, "input appears to be interlaced, but not compiled with interlaced support\n" );
+#endif
     }
 
     /* Automatically reduce reference frame count to match the user's target level