From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org [79.124.17.100]) by master.gitmailbox.com (Postfix) with ESMTP id B8D594705B for ; Sat, 26 Aug 2023 01:11:02 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 1284468C622; Sat, 26 Aug 2023 04:10:45 +0300 (EEST) Received: from mail-wm1-f44.google.com (mail-wm1-f44.google.com [209.85.128.44]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 4150968C5FC for ; Sat, 26 Aug 2023 04:10:36 +0300 (EEST) Received: by mail-wm1-f44.google.com with SMTP id 5b1f17b1804b1-3fed963273cso15561525e9.1 for ; Fri, 25 Aug 2023 18:10:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1693012234; x=1693617034; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=UEoKb4egs/XIIbGjzhrM3bxN3ttZzbH18MmnKEzZuNc=; b=JcshNB0jNYlhUDvdTMoN9aaX5CcTZysoDPtQ2SYwh9q3sAT9R01tLgsZeP6rwWkAh5 UJsOWeA47KpbqwBTKOg+3Okzm/qkLv0faHPG+t9c7wla1ZYvYybsPnmeimY92gVb4GH+ l95P0DoOpp5HcV+8zsWn/4+SxntoNDyP/5Bt8pq551u+oZcK2jo5ELnqE4UHsr5MhGLf 6zLs/HUiWrRnYw5V2JTY+dhKn5dbi/f1cARsNvO0zuUHeYIgrh3MCQt/rX637IkGh2ZC RYHh2S5i92Ls41OiwvaC7CpiooSIG4WT6Wr8wsAbuyPwCmFBT3iriceWIH6i0ahz9VyQ 0MiA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1693012234; x=1693617034; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=UEoKb4egs/XIIbGjzhrM3bxN3ttZzbH18MmnKEzZuNc=; b=lUlAHCYzqMgSuQ/3fkcZ23ZoGObhgm5jYeZs/vtYuJjflOgPGVEdQulkOowMJ46JFp KVmI2nhSXKU0QC9a1trLC4dZxi6W5gdiiACUGT+iF2iCqzHPpxFS/0f+YLlJyFy2Zoqt +tUxu/uCJwtihusp+0ul7X2lgaeqXdvYXNkwmL2jPExb2J14lplTW4mhcRg8CXgapMlN sU+8UMa27lj3sv7/HT1W1MTuHShYGwgsB/dR4mc46hTXyKXZSPuUiPcvkDWGLyyv4eQs jBrghqYMRfK0taSh6IHZdChGh6ivx/2+qZhd+az8wAYja9otA8AnifcukFY04KTft+Cj Y+pA== X-Gm-Message-State: AOJu0YyT8x1ZKLnSV7TqgP/PUk1n9/h6kVw2n/ELx3whjET4pOvCXxSW HI5CWC6yLf13BNNModclnThESPF7MGA= X-Google-Smtp-Source: AGHT+IHUbI0pzEn2Z+9uJbJ2oNblEVFI/cnOBNlL9Lnso7ysYwjl3TpVpu4iMBaZq9HOUJvpeePrHg== X-Received: by 2002:a5d:4b8f:0:b0:317:4bde:9e72 with SMTP id b15-20020a5d4b8f000000b003174bde9e72mr19529749wrt.10.1693012233684; Fri, 25 Aug 2023 18:10:33 -0700 (PDT) Received: from mariano ([82.84.194.139]) by smtp.gmail.com with ESMTPSA id m17-20020a5d6a11000000b003142e438e8csm3512117wru.26.2023.08.25.18.10.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 25 Aug 2023 18:10:32 -0700 (PDT) Received: by mariano (Postfix, from userid 1000) id ABB82BFCDA; Sat, 26 Aug 2023 03:10:30 +0200 (CEST) From: Stefano Sabatini To: FFmpeg development discussions and patches Date: Sat, 26 Aug 2023 03:10:28 +0200 Message-Id: <20230826011030.76116-1-stefasab@gmail.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Subject: [FFmpeg-devel] [PATCH 1/3] doc/encoders/libx264: review and extend option description X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Stefano Sabatini Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Archived-At: List-Archive: List-Post: Also, merge x264opts and x264-opts option docs to avoid duplication and make it even more clearer they provide the same functionality. --- doc/encoders.texi | 66 ++++++++++++++++++++++++++--------------------- 1 file changed, 37 insertions(+), 29 deletions(-) diff --git a/doc/encoders.texi b/doc/encoders.texi index 6f8f5e127e..947b0c3320 100644 --- a/doc/encoders.texi +++ b/doc/encoders.texi @@ -2418,6 +2418,10 @@ To get a more accurate and extensive documentation of the libx264 options, invoke the command @command{x264 --fullhelp} or consult the libx264 documentation. +In the list below, note that the @command{x264} option name is shown +in parentheses after the libavcodec corresponding name, in case there +is a direct mapping. + @table @option @item b (@emph{bitrate}) Set bitrate in bits/s. Note that FFmpeg's @option{b} option is @@ -2425,17 +2429,19 @@ expressed in bits/s, while @command{x264}'s @option{bitrate} is in kilobits/s. @item bf (@emph{bframes}) +Number of B-frames between I and P-frames @item g (@emph{keyint}) +Maximum GOP size @item qmin (@emph{qpmin}) -Minimum quantizer scale. +Minimum quantizer scale @item qmax (@emph{qpmax}) -Maximum quantizer scale. +Maximum quantizer scale @item qdiff (@emph{qpstep}) -Maximum difference between quantizer scales. +Maximum difference between quantizer scales @item qblur (@emph{qblur}) Quantizer curve blur @@ -2444,7 +2450,7 @@ Quantizer curve blur Quantizer curve compression factor @item refs (@emph{ref}) -Number of reference frames each P-frame can use. The range is from @var{0-16}. +Number of reference frames each P-frame can use. The allowed range is @var{0-16}. @item sc_threshold (@emph{scenecut}) Sets the threshold for the scene change detection. @@ -2452,7 +2458,8 @@ Sets the threshold for the scene change detection. @item trellis (@emph{trellis}) Performs Trellis quantization to increase efficiency. Enabled by default. -@item nr (@emph{nr}) +@item nr (@emph{nr}) +Noise reduction @item me_range (@emph{merange}) Maximum range of the motion search in pixels. @@ -2533,6 +2540,7 @@ open GOP by setting it to @code{-cgop}. The result is similar to the behavior of @command{x264}'s @option{--open-gop} option. @item rc_init_occupancy (@emph{vbv-init}) +Initial VBV buffer occupancy @item preset (@emph{preset}) Set the encoding preset. @@ -2578,7 +2586,7 @@ Set AQ strength, reduce blocking and blurring in flat and textured areas. Use psychovisual optimizations when set to 1. When set to 0, it has the same effect as @command{x264}'s @option{--no-psy} option. -@item psy-rd (@emph{psy-rd}) +@item psy-rd (@emph{psy-rd}) Set strength of psychovisual optimization, in @var{psy-rd}:@var{psy-trellis} format. @@ -2610,7 +2618,7 @@ to 1. @item avcintra-class (@emph{class}) Configure the encoder to generate AVC-Intra. -Valid values are 50,100 and 200 +Valid values are 50, 100 and 200 @item bluray-compat (@emph{bluray-compat}) Configure the encoder to be compatible with the bluray standard. @@ -2661,8 +2669,8 @@ Set loop filter parameters, in @var{alpha}:@var{beta} form. Set fluctuations reduction in QP (before curve compression). @item partitions (@emph{partitions}) -Set partitions to consider as a comma-separated list of. Possible -values in the list: +Set partitions to consider as a comma-separated list of +values. Possible values in the list: @table @samp @item p8x8 @@ -2718,19 +2726,33 @@ Variable bit rate. Constant bit rate (not allowed in MP4 container). @end table -@item x264opts (N.A.) -Set any x264 option, see @command{x264 --fullhelp} for a list. +@item x264opts @var{opts} +@item x264-params @var{opts} +Override the x264 configuration using a :-separated list of key=value +options. -Argument is a list of @var{key}=@var{value} couples separated by -":". In @var{filter} and @var{psy-rd} options that use ":" as a separator -themselves, use "," instead. They accept it as well since long ago but this -is kept undocumented for some reason. +@option{x264-param} is functionally the same as the @option{x264opts}, +but is duplicated for compatibility with the Libav fork. + +The argument for both options is a list of @var{key}=@var{value} +couples separated by ":". In @var{filter} and @var{psy-rd} options +that use ":" as a separator themselves, use "," instead. They accept +it as well since long ago but this is kept undocumented for some +reason. + +For example, the options might be provided as: +@example +level=30:bframes=0:weightp=0:cabac=0:ref=1:vbv-maxrate=768:vbv-bufsize=2000:analyse=all:me=umh:no-fast-pskip=1:subq=6:8x8dct=0:trellis=0 +@end example For example to specify libx264 encoding options with @command{ffmpeg}: @example ffmpeg -i foo.mpg -c:v libx264 -x264opts keyint=123:min-keyint=20 -an out.mkv @end example +To get the complete list of the libx264 options, invoke the command +@command{x264 --fullhelp} or consult the libx264 documentation. + @item a53cc @var{boolean} Import closed captions (which must be ATSC compatible format) into output. Only the mpeg2 and h264 decoders provide these. Default is 1 (on). @@ -2741,20 +2763,6 @@ Import user data unregistered SEI if available into output. Default is 0 (off). @item mb_info @var{boolean} Set mb_info data through AVFrameSideData, only useful when used from the API. Default is 0 (off). - -@item x264-params (N.A.) -Override the x264 configuration using a :-separated list of key=value -parameters. - -This option is functionally the same as the @option{x264opts}, but is -duplicated for compatibility with the Libav fork. - -For example to specify libx264 encoding options with @command{ffmpeg}: -@example -ffmpeg -i INPUT -c:v libx264 -x264-params level=30:bframes=0:weightp=0:\ -cabac=0:ref=1:vbv-maxrate=768:vbv-bufsize=2000:analyse=all:me=umh:\ -no-fast-pskip=1:subq=6:8x8dct=0:trellis=0 OUTPUT -@end example @end table Encoding ffpresets for common usages are provided so they can be used with the -- 2.34.1 _______________________________________________ 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".