aboutsummaryrefslogtreecommitdiff
path: root/transcode.sh.1
diff options
context:
space:
mode:
authorDennis Fink2026-05-09 21:30:38 +0200
committerDennis Fink2026-05-09 21:30:38 +0200
commit46e56972f2b4d16ca6b3fd04611f86cf8580ea10 (patch)
treeadd502327a7f85c9b9b7af60abea617c5f246085 /transcode.sh.1
parentcfeb338478bb67defce2fb48222a6be3cffc4263 (diff)
downloadtranscode.sh-46e56972f2b4d16ca6b3fd04611f86cf8580ea10.tar.gz
transcode.sh-46e56972f2b4d16ca6b3fd04611f86cf8580ea10.zip
feat(core,cli): add hardware acceleration support via --hwaccel
Add --hwaccel [METHOD] / --no-hwaccel flags to control whether -hwaccel is passed to ffmpeg before the input file. The METHOD argument is optional and defaults to "auto", letting ffmpeg select the best available hardware decoder with automatic software fallback. Hardware acceleration is enabled by default (method: auto). Users on hosts where hwaccel causes compatibility or stability issues can opt out with --no-hwaccel or config.toml [encoding] hwaccel = false. The config key accepts false (disable), true (auto), or a method string such as "vaapi" or "cuda". CLI flags take precedence as usual. Bash completion is extended with a hwaccel_methods word list (auto, cuda, vaapi, dxva2, d3d11va, videotoolbox, qsv) for both the space form (--hwaccel <TAB>) and the equals form (--hwaccel=<TAB>). The completion script is also reformatted from 4-space to 2-space indentation for consistency with transcode.sh itself.
Diffstat (limited to 'transcode.sh.1')
-rw-r--r--transcode.sh.145
1 files changed, 45 insertions, 0 deletions
diff --git a/transcode.sh.1 b/transcode.sh.1
index edeaae8..46b7526 100644
--- a/transcode.sh.1
+++ b/transcode.sh.1
@@ -86,6 +86,37 @@ Combine with
.B \-v
to see the detected codec and pixel format information.
.TP
+.BR \-\-hwaccel " [\fIMETHOD\fR], " \-\-hwaccel= \fIMETHOD\fR
+Pass
+.BI \-hwaccel " METHOD"
+to
+.BR ffmpeg (1)
+before the input file, enabling hardware-accelerated decoding.
+\fIMETHOD\fR is optional; when omitted it defaults to
+.BR auto ,
+which lets
+.BR ffmpeg (1)
+select the best available hardware decoder and fall back to software
+automatically.
+Common values include
+.BR cuda ,
+.BR vaapi ,
+.BR dxva2 ,
+and
+.BR videotoolbox .
+Hardware acceleration is
+.B enabled by default
+(method
+.BR auto ).
+.TP
+.B \-\-no\-hwaccel
+Do not pass
+.B \-hwaccel
+to
+.BR ffmpeg (1).
+Use this on hosts where hardware acceleration causes compatibility or
+stability issues.
+.TP
.BR \-N " \fIVALUE\fR, " \-\-nice " \fIVALUE\fR, " \-\-nice= \fIVALUE\fR
Run
.BR ffmpeg (1)
@@ -287,6 +318,20 @@ String. Default preset name. Equivalent to
Integer. Default niceness value. Equivalent to
.BR \-N .
.TP
+.B [encoding] hwaccel
+String or boolean.
+.B false
+disables hardware acceleration.
+.B true
+enables it with method
+.BR auto .
+Any other string (e.g.\&
+.IR vaapi ,
+.IR cuda )
+enables it with that specific method.
+Equivalent to
+.BR \-\-hwaccel " / " \-\-no\-hwaccel .
+.TP
.B [encoding] verify_output
Boolean. Equivalent to
.BR \-\-verify\-output / \-\-no\-verify\-output .