From 6fff195cd153efb791e0f75389a747e3a10f50a2 Mon Sep 17 00:00:00 2001 From: Jonathan Baecker Date: Fri, 7 Jun 2019 16:12:09 +0200 Subject: [PATCH] starting with text overlay --- ffplayout.py | 4 +++- live.txt | 1 + 2 files changed, 4 insertions(+), 1 deletion(-) create mode 100644 live.txt diff --git a/ffplayout.py b/ffplayout.py index b6382763..a1f4e2b7 100755 --- a/ffplayout.py +++ b/ffplayout.py @@ -1023,7 +1023,9 @@ def main(): if _playout.preview: # preview playout to player encoder = Popen([ - 'ffplay', '-hide_banner', '-nostats', '-i', 'pipe:0'], + 'ffplay', '-hide_banner', '-nostats', '-i', 'pipe:0', + '-vf', "drawtext=enable='gte(t,3)':box=1:boxcolor=0x000000@0xcc:boxborderw=8:fontsize=24:fontcolor=white:textfile=live.txt:reload=1:y=(h-line_h)*0\,9:x=w-w/8*mod(t\,8*(w+tw)/w)" + ], stderr=None, stdin=PIPE, stdout=None ) else: diff --git a/live.txt b/live.txt new file mode 100644 index 00000000..4fd0835e --- /dev/null +++ b/live.txt @@ -0,0 +1 @@ +This is a very important news! ... \ No newline at end of file