DOKK / manpages / debian 12 / libavif-bin / avifenc.1.en
AVIFENC(1) General Commands Manual AVIFENC(1)

avifenc - compress an image file to an AVIF file

avifenc [options] input.[jpg|jpeg|png|y4m] output.avif

avifenc compresses an image file to an AVIF file. Input format can be either JPEG, PNG or YUV4MPEG2 (Y4M).

Show syntax help.
Show the version number.
Number of jobs (worker threads). 1 or less means single-threaded. Default is 1. Use all to use all available cores.
Instead of using the last filename given as output, use this filename.
Set all defaults to encode losslessly, and emit warnings when settings/input don’t allow for it.
Output depth. This is available if the input format is JPEG/PNG, and for y4m or stdin, depth is retained.
8
10
12
Output format. Ignored for y4m or stdin (y4m format is retained). For JPEG, auto honors the JPEG’s internal format, if possible. For all other cases, auto defaults to 444.
auto (default)
444
422
420
400
Premultiply color by the alpha channel and signal this in the AVIF.
Use sharp RGB to YUV420 conversion (if supported). Ignored for y4m or if output is not 420.
Read y4m frames from stdin instead of files. No input filenames allowed, must be set before specifying the output filename.
Specify CICP values (nclx colr box) by 3 raw numbers. Use 2 for any you wish to leave unspecified.
P = color primaries
T = transfer characteristics
M = matrix coefficients
YUV range. This is available if the input format is JPEG/PNG, and for y4m or stdin, range is retained.
full, f (default)
limited, l
Set min quantizer for color. Possible values are in the range 0-63, where 0 is lossless.
Set max quantizer for color. Possible values are in the range 0-63, where 0 is lossless.
Set min quantizer for alpha. Possible values are in the range 0-63, where 0 is lossless.
Set max quantizer for alpha. Possible values are in the range 0-63, where 0 is lossless.
Set log2 of number of tile rows. Possible values are in the range 0-6. Default is 0.
Set log2 of number of tile columns. Possible values are in the range 0-6. Default is 0.
Set --tilerowslog2 and --tilecolslog2 automatically.
Encode a single-image grid AVIF with M cols and N rows. Either supply MxN images of the same width, height and depth, or a single image that can be evenly split into the MxN grid and follow AVIF grid image restrictions. The grid will adopt the color profile of the first image supplied. Possible values for M and N are in the range 1-256.
Encoder speed. Default is 6.
0-10 (slowest-fastest)
default, d (codec internal defaults)
AV1 codec to use. Possible values depend on the codecs enabled at build time (see --help or --version for the available codecs). Default is auto-selected from the available codecs.
aom
rav1e
svt
Provide an Exif metadata payload to be associated with the primary item (implies –ignore-exif).
Provide an XMP metadata payload to be associated with the primary item (implies –ignore-xmp).
Provide an ICC profile payload to be associated with the primary item (implies –ignore-icc).
Pass an advanced, codec-specific key/value string pair directly to the codec. avifenc will warn on any unused by the codec. The aom-specific advanced options can be used if the AOM codec is available (see --help for details).
Set all following frame durations (in timescales) to D. Can be set multiple times (before supplying each filename). Default is 1.
Set the timescale to V. If all frames are 1 timescale in length, this is equivalent to frames per second. If neither duration nor timescale are set, avifenc will attempt to use the framerate stored in a y4m header, if present. Default is 30.
Set the forced keyframe interval (maximum frames between keyframes). Set to 0 to disable. Default is 0.
If the input file contains embedded Exif metadata, ignore it (no-op if absent).
If the input file contains embedded XMP metadata, ignore it (no-op if absent).
If the input file contains an embedded ICC profile, ignore it (no-op if absent).
Add pasp property (aspect ratio).
H = horizontal spacing
V = vertical spacing
Add clap property (clean aperture), but calculated from a crop rectangle.
CROPX = X-axis of a crop rectangle
CROPY = Y-axis of a crop rectangle
CROPW = width of a crop rectangle
CROPH = height of a crop rectangle
Add clap property (clean aperture).
WN = numerator of width
WD = denominator of width
HN = numerator of height
HD = denominator of height
HON = numerator of horizontal offset
HOD = denominator of horizontal offset
VON = numerator of vertical offset
VOD = denominator of vertical offset
Add irot property (rotation). Possible values are in the range 0-3, and makes (90 * ANGLE) degree rotation anti-clockwise.
Add imir property (mirroring).

Note: Rotation is applied before mirroring at rendering.

0 (top-to-bottom)
1 (left-to-right)
--
Signals the end of options. Everything after this is interpreted as file names.

$ avifenc input.png output.avif

<https://github.com/AOMediaCodec/libavif/issues>

avifdec(1)

2022-04-30 libavif 0.11.1