From 7c302ecee9bdb7a53b2fc03d9d63693996566010 Mon Sep 17 00:00:00 2001 From: Dennis Fink Date: Tue, 24 Feb 2026 21:08:38 +0100 Subject: docs: document all variables available to presets Previously only output_pixel_format was mentioned. All three variables (input_codec, input_pixel_format, output_pixel_format) are now listed with descriptions in the script header comment, the README, and the man page. --- README.md | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'README.md') diff --git a/README.md b/README.md index 4001672..64dd6c0 100644 --- a/README.md +++ b/README.md @@ -77,8 +77,13 @@ ${XDG_CONFIG_HOME:-$HOME/.config}/transcode.sh/presets/.sh ``` Each preset is sourced as Bash and must define an array named `ffargs`. -The variable `output_pixel_format` is available and contains the -automatically selected pixel format (derived from the input file). +The following variables are available to presets at source time: + +| Variable | Description | +|----------|-------------| +| `input_codec` | Video codec of the input file (e.g. `h264`, `hevc`) | +| `input_pixel_format` | Pixel format of the input after `yuvj*` normalisation (e.g. `yuv420p`) | +| `output_pixel_format` | Recommended output pixel format, derived from the input to preserve chroma subsampling and bit depth | Before the preset's `ffargs` are appended, the script always passes these base arguments to `ffmpeg`: -- cgit v1.3.1