[FFmpeg-devel] [PATCH 2/2] ffmpeg: add -(no)stdin option.

Nicolas George nicolas.george at normalesup.org
Sat Jul 14 19:18:50 CEST 2012


Allows to disable interaction from standard input.
Useful, for example, if ffmpeg is in the background process group.
Roughly the same result can be achieved with "ffmpeg ... < /dev/null"
but it requires a shell.

Signed-off-by: Nicolas George <nicolas.george at normalesup.org>
---
 Changelog |    1 +
 ffmpeg.c  |    2 ++
 2 files changed, 3 insertions(+)

diff --git a/Changelog b/Changelog
index fc5becb..dfe8811 100644
--- a/Changelog
+++ b/Changelog
@@ -27,6 +27,7 @@ version next:
 - iec61883 device
 - asettb filter
 - new option: -progress
+- ffmpeg -(no)stdin option
 
 
 version 0.11:
diff --git a/ffmpeg.c b/ffmpeg.c
index 3acdf48..7547f88 100644
--- a/ffmpeg.c
+++ b/ffmpeg.c
@@ -5875,6 +5875,8 @@ static const OptionDef options[] = {
       "add timings for each task" },
     { "progress", HAS_ARG | OPT_EXPERT, {(void*)opt_progress},
       "write program-readable progress information", "url" },
+    { "stdin", OPT_BOOL | OPT_EXPERT, {(void*)&stdin_interaction},
+      "enable or disable interaction on standard input" },
     { "timelimit", HAS_ARG, {(void*)opt_timelimit}, "set max runtime in seconds", "limit" },
     { "dump", OPT_BOOL | OPT_EXPERT, {(void*)&do_pkt_dump},
       "dump each input packet" },
-- 
1.7.10.4



More information about the ffmpeg-devel mailing list