summaryrefslogtreecommitdiff
path: root/README.md
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--README.md18
1 files changed, 17 insertions, 1 deletions
diff --git a/README.md b/README.md
index 65db49a..4001672 100644
--- a/README.md
+++ b/README.md
@@ -59,8 +59,9 @@ install -Dm644 transcode.sh.bash-completion \
```
> **PATH note:** the script resets `PATH` to `/bin:/usr/bin:/usr/local/bin`
-> for security. If your `ffmpeg` lives elsewhere (e.g. Homebrew on macOS,
+> for security. If your `ffmpeg` lives elsewhere (e.g. Homebrew on macOS,
> Nix), prepend its directory:
+>
> ```sh
> PATH="/opt/homebrew/bin:$PATH" transcode.sh input.mp4
> ```
@@ -79,6 +80,21 @@ 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).
+Before the preset's `ffargs` are appended, the script always passes
+these base arguments to `ffmpeg`:
+
+```
+-map 0 # include all streams from the input
+-map_metadata 0 # copy all container-level metadata
+-map_chapters 0 # copy all chapter markers
+-c copy # default to stream copy for every stream
+```
+
+A preset therefore only needs to specify the streams it wishes to
+re-encode (typically `-c:v:0`) and any associated encoder options.
+All other streams — audio, subtitles, attachments — are passed through
+unchanged unless the preset explicitly overrides them.
+
**Example — `~/.config/transcode.sh/presets/default.sh`:**
```sh