OptionalalphaThe quality of the alpha channel (if the image has transparency), like avifenc's. Default: 100 (lossless)
OptionaleffortHow hard the encoder searches for the best modes: 0-2, faster to smaller. Default: 1
OptionalmetadataMetadata to include, see Metadata
Optionalquality0-100, like avifenc's: higher is better and larger, 100 is lossless. Default: 60
OptionalsubsamplingChroma subsampling: '4:4:4' keeps the full color resolution, '4:2:0' halves it (smaller). Default: '4:4:4'
OptionalthreadsAt most this many worker threads encode in parallel (the same file, faster: 2.9 times with 8 on a 1920x1080
photo at effort 1), 1 for none. Small images (under about 640x640 pixels at effort 0, 448x448 at 1, 320x320
at 2), and runtimes whose workers can't share memory (browsers without cross-origin isolation), encode without
them. Default: the processors available, at most 8
Options of Image.encodeAVIF