== P1 list characters (vi.srt) published: python3 srt-chars.py subs.srt as run: python3 srt-chars.py ../srt/vi.srt 19 characters outside plain ASCII: áãòĐđơưạảấầắặẹỗớờứừ exit=0 == P1 edge ASCII only edge: plain ASCII file (en.srt) published: python3 srt-chars.py subs.srt as run: python3 srt-chars.py ../srt/en.srt Only plain ASCII characters in this file; any Latin font covers them. exit=0 == P1 edge CRLF+BOM edge: Windows line breaks plus BOM (pl.srt converted) published: python3 srt-chars.py subs.srt as run: python3 srt-chars.py crlf.srt 7 characters outside plain ASCII: óąćęłśż exit=0 == P1 edge missing file edge: missing file published: python3 srt-chars.py subs.srt as run: python3 srt-chars.py nope.srt error: file not found: nope.srt exit=2 == P1 edge empty file edge: empty file published: python3 srt-chars.py subs.srt as run: python3 srt-chars.py empty.srt error: empty.srt is empty exit=2 == P1 edge Windows-1250 edge: not UTF-8 (cs.srt saved as Windows-1250) published: python3 srt-chars.py subs.srt as run: python3 srt-chars.py cp1250.srt error: cp1250.srt is not UTF-8. Save it as UTF-8 in your editor and run again. exit=2 == P1 edge NFD edge: NFD file (accents as separate marks) published: python3 srt-chars.py subs.srt as run: python3 srt-chars.py ../srt/vi-nfd.srt 10 characters outside plain ASCII: Đđ̛̣̀́̂̃̆̉ note: 8 combining accent marks found; the file is not in NFC form. exit=0 == P1 edge non-ASCII digits edge: cue text made only of non-ASCII digits (Arabic-Indic 123); only ASCII digit lines count as cue numbers published: python3 srt-chars.py subs.srt as run: python3 srt-chars.py ardigits.srt 3 characters outside plain ASCII: ١٢٣ exit=0 == P2 font check, lacking font (vi.srt + Bebas Neue) published: python3 srt-chars.py subs.srt font.ttf as run: python3 srt-chars.py ../srt/vi.srt fonts-bebas/BebasNeue-Regular.ttf 19 characters outside plain ASCII: áãòĐđơưạảấầắặẹỗớờứừ The font has no glyph for 14 of 45 characters used: U+01A1 ơ LATIN SMALL LETTER O WITH HORN U+01B0 ư LATIN SMALL LETTER U WITH HORN U+1EA1 ạ LATIN SMALL LETTER A WITH DOT BELOW U+1EA3 ả LATIN SMALL LETTER A WITH HOOK ABOVE U+1EA5 ấ LATIN SMALL LETTER A WITH CIRCUMFLEX AND ACUTE U+1EA7 ầ LATIN SMALL LETTER A WITH CIRCUMFLEX AND GRAVE U+1EAF ắ LATIN SMALL LETTER A WITH BREVE AND ACUTE U+1EB7 ặ LATIN SMALL LETTER A WITH BREVE AND DOT BELOW U+1EB9 ẹ LATIN SMALL LETTER E WITH DOT BELOW U+1ED7 ỗ LATIN SMALL LETTER O WITH CIRCUMFLEX AND TILDE U+1EDB ớ LATIN SMALL LETTER O WITH HORN AND ACUTE U+1EDD ờ LATIN SMALL LETTER O WITH HORN AND GRAVE U+1EE9 ứ LATIN SMALL LETTER U WITH HORN AND ACUTE U+1EEB ừ LATIN SMALL LETTER U WITH HORN AND GRAVE exit=1 == P2 font check, covering font (vi.srt + Inter Bold) published: python3 srt-chars.py subs.srt font.ttf as run: python3 srt-chars.py ../srt/vi.srt fonts-fix/Inter-Bold.ttf 19 characters outside plain ASCII: áãòĐđơưạảấầắặẹỗớờứừ The font has a glyph for all 45 characters used. exit=0 == P2 edge missing font edge: font path wrong published: python3 srt-chars.py subs.srt font.ttf as run: python3 srt-chars.py ../srt/vi.srt nofont.ttf error: font not found: nofont.ttf 19 characters outside plain ASCII: áãòĐđơưạảấầắặẹỗớờứừ exit=2 == P2 edge not a font edge: a file that is not a font (the SRT given as the font) published: python3 srt-chars.py subs.srt font.ttf as run: python3 srt-chars.py ../srt/vi.srt ../srt/ru.srt error: cannot read the font ../srt/ru.srt: Not a TrueType or OpenType font (bad sfntVersion) 19 characters outside plain ASCII: áãòĐđơưạảấầắặẹỗớờứừ exit=2 == P2 edge OTF font edge: OTF (CFF) font, which the browser inspector does not take: tiny.otf built by mkotf.py with glyphs for A, a and the Romanian/Vietnamese a-breve only published: python3 srt-chars.py subs.srt font.ttf as run: python3 srt-chars.py otf-test.srt tiny.otf 1 character outside plain ASCII: ă The font has a glyph for all 3 characters used. exit=0 == P2 edge font over 1 MB edge: TTF over the inspector's 1 MB limit (NotoSansSignWriting-Regular.ttf, 5.2 MB, a sign-writing font with no Latin letters) published: python3 srt-chars.py subs.srt font.ttf as run: python3 srt-chars.py ../srt/vi.srt /usr/share/fonts/truetype/noto/NotoSansSignWriting-Regular.ttf | sed -n 3p; exit ${PIPESTATUS[0]} The font has no glyph for 45 of 45 characters used: exit=1 == P3 which font file libass really used (vi.srt, Bebas Neue, normal system) published: ffmpeg -v verbose -i video.mp4 -vf "subtitles=subs.srt:fontsdir=fonts:force_style='FontName=Bebas Neue'" -f null - 2>&1 | grep fontselect | sort | uniq -c as run: ffmpeg -v verbose -i video.mp4 -vf "subtitles=../srt/vi.srt:fontsdir=fonts-bebas:force_style='FontName=Bebas Neue'" -f null - 2>&1 | grep fontselect | sort | uniq -c 1 [Parsed_subtitles_0 @ 0x59dad89e43c0] fontselect: (Bebas Neue, 400, 0) -> /usr/share/fonts/truetype/noto/NotoSans-Regular.ttf, 0, NotoSans-Regular 1 [Parsed_subtitles_0 @ 0x59dad89e43c0] fontselect: (Bebas Neue, 400, 0) -> BebasNeue-Regular, 0, BebasNeue-Regular exit=0 == P3 edge no fallback fonts edge: system with no fallback fonts (FONTCONFIG_FILE with no font folders) published: ffmpeg -v verbose -i video.mp4 -vf "subtitles=subs.srt:fontsdir=fonts:force_style='FontName=Bebas Neue'" -f null - 2>&1 | grep fontselect | sort | uniq -c as run: FONTCONFIG_FILE=$PWD/../empty-fc/fonts.conf ffmpeg -v verbose -i video.mp4 -vf "subtitles=../srt/vi.srt:fontsdir=fonts-bebas:force_style='FontName=Bebas Neue'" -f null - 2>&1 | grep fontselect | sort | uniq -c 1 [Parsed_subtitles_0 @ 0x607761b2d600] fontselect: (Bebas Neue, 400, 0) -> BebasNeue-Regular, 0, BebasNeue-Regular 360 [Parsed_subtitles_0 @ 0x607761b2d600] fontselect: failed to find any fallback with glyph 0x1A1 for font: (Bebas Neue, 400, 0) 360 [Parsed_subtitles_0 @ 0x607761b2d600] fontselect: failed to find any fallback with glyph 0x1B0 for font: (Bebas Neue, 400, 0) 120 [Parsed_subtitles_0 @ 0x607761b2d600] fontselect: failed to find any fallback with glyph 0x1EA1 for font: (Bebas Neue, 400, 0) 120 [Parsed_subtitles_0 @ 0x607761b2d600] fontselect: failed to find any fallback with glyph 0x1EA3 for font: (Bebas Neue, 400, 0) 120 [Parsed_subtitles_0 @ 0x607761b2d600] fontselect: failed to find any fallback with glyph 0x1EA5 for font: (Bebas Neue, 400, 0) 360 [Parsed_subtitles_0 @ 0x607761b2d600] fontselect: failed to find any fallback with glyph 0x1EA7 for font: (Bebas Neue, 400, 0) 120 [Parsed_subtitles_0 @ 0x607761b2d600] fontselect: failed to find any fallback with glyph 0x1EAF for font: (Bebas Neue, 400, 0) 120 [Parsed_subtitles_0 @ 0x607761b2d600] fontselect: failed to find any fallback with glyph 0x1EB7 for font: (Bebas Neue, 400, 0) 120 [Parsed_subtitles_0 @ 0x607761b2d600] fontselect: failed to find any fallback with glyph 0x1EB9 for font: (Bebas Neue, 400, 0) 120 [Parsed_subtitles_0 @ 0x607761b2d600] fontselect: failed to find any fallback with glyph 0x1ED7 for font: (Bebas Neue, 400, 0) 120 [Parsed_subtitles_0 @ 0x607761b2d600] fontselect: failed to find any fallback with glyph 0x1EDB for font: (Bebas Neue, 400, 0) 120 [Parsed_subtitles_0 @ 0x607761b2d600] fontselect: failed to find any fallback with glyph 0x1EDD for font: (Bebas Neue, 400, 0) 120 [Parsed_subtitles_0 @ 0x607761b2d600] fontselect: failed to find any fallback with glyph 0x1EE9 for font: (Bebas Neue, 400, 0) 120 [Parsed_subtitles_0 @ 0x607761b2d600] fontselect: failed to find any fallback with glyph 0x1EEB for font: (Bebas Neue, 400, 0) exit=0 == P3 edge misspelled name edge: font name misspelled (FontName=Intr) published: ffmpeg -v verbose -i video.mp4 -vf "subtitles=subs.srt:fontsdir=fonts:force_style='FontName=Bebas Neue'" -f null - 2>&1 | grep fontselect | sort | uniq -c as run: ffmpeg -v verbose -i video.mp4 -vf "subtitles=../srt/vi.srt:fontsdir=fonts-fix:force_style='FontName=Intr'" -f null - 2>&1 | grep fontselect | sort | uniq -c 1 [Parsed_subtitles_0 @ 0x63693d3f3000] fontselect: (Intr, 400, 0) -> /usr/share/fonts/truetype/noto/NotoSans-Regular.ttf, 0, NotoSans-Regular exit=0 == P3 edge wrong fontsdir folder edge: fontsdir names a folder that does not exist (nofonts) published: ffmpeg -v verbose -i video.mp4 -vf "subtitles=subs.srt:fontsdir=fonts:force_style='FontName=Bebas Neue'" -f null - 2>&1 | grep fontselect | sort | uniq -c as run: ffmpeg -v verbose -i video.mp4 -vf "subtitles=../srt/vi.srt:fontsdir=nofonts:force_style='FontName=Inter'" -f null - 2>&1 | grep fontselect | sort | uniq -c 1 [Parsed_subtitles_0 @ 0x5fe289471c40] fontselect: (Inter, 400, 0) -> /usr/share/fonts/truetype/noto/NotoSans-Regular.ttf, 0, NotoSans-Regular exit=0 == P3 edge wrong subtitle path edge: subtitle path wrong (nosuch.srt): the pipeline prints nothing and exits 0; the second run, without the part after 2>&1, shows the error published: ffmpeg -v verbose -i video.mp4 -vf "subtitles=subs.srt:fontsdir=fonts:force_style='FontName=Bebas Neue'" -f null - 2>&1 | grep fontselect | sort | uniq -c as run: ffmpeg -v verbose -i video.mp4 -vf "subtitles=nosuch.srt:fontsdir=fonts-bebas:force_style='FontName=Bebas Neue'" -f null - 2>&1 | grep fontselect | sort | uniq -c; echo pipeline-exit=$?; ffmpeg -v error -i video.mp4 -vf "subtitles=nosuch.srt:fontsdir=fonts-bebas:force_style='FontName=Bebas Neue'" -f null - 2>&1 | tail -3 pipeline-exit=0 [vost#0:0/wrapped_avframe @ 0x55d196c74900] Error initializing a simple filtergraph Error opening output file -. Error opening output files: No such file or directory exit=0 == P4 burn again with the covering font named (ru.srt, Inter) published: ffmpeg -i video.mp4 -vf "subtitles=subs.srt:fontsdir=fonts:force_style='FontName=Inter'" -c:a copy burned.mp4 as run: ffmpeg -v error -y -i video.mp4 -vf "subtitles=../srt/ru.srt:fontsdir=fonts-fix:force_style='FontName=Inter'" -c:a copy burned.mp4 && ffprobe -v error -show_entries stream=codec_type,codec_name -of csv=p=0 burned.mp4 && ffmpeg -v verbose -i video.mp4 -t 1 -vf "subtitles=../srt/ru.srt:fontsdir=fonts-fix:force_style='FontName=Inter'" -f null - 2>&1 | grep -o 'fontselect.*' | sort -u h264,video aac,audio fontselect: (Inter, 400, 0) -> Inter-Bold, 0, Inter-Bold exit=0 == P4 edge no audio edge: video with no audio track published: ffmpeg -i video.mp4 -vf "subtitles=subs.srt:fontsdir=fonts:force_style='FontName=Inter'" -c:a copy burned.mp4 as run: ffmpeg -v error -y -i video.mp4 -an -c:v copy noaudio.mp4 && ffmpeg -v error -y -i noaudio.mp4 -vf "subtitles=../srt/ru.srt:fontsdir=fonts-fix:force_style='FontName=Inter'" -c:a copy burned2.mp4 && ffprobe -v error -show_entries stream=codec_type -of csv=p=0 burned2.mp4 video exit=0 == P4 edge CRLF+BOM edge: CRLF+BOM subtitle file published: ffmpeg -i video.mp4 -vf "subtitles=subs.srt:fontsdir=fonts:force_style='FontName=Inter'" -c:a copy burned.mp4 as run: ffmpeg -v error -y -i video.mp4 -t 3 -vf "subtitles=crlf.srt:fontsdir=fonts-fix:force_style='FontName=Inter'" -c:a copy burned3.mp4 && ffprobe -v error -show_entries format=duration -of csv=p=0 burned3.mp4 3.015000 exit=0 == P4 edge colon in file name edge: subtitle file name with a colon and a space (Ep 1: Intro.srt); the same file renamed to ep1.srt burns published: ffmpeg -i video.mp4 -vf "subtitles=subs.srt:fontsdir=fonts:force_style='FontName=Inter'" -c:a copy burned.mp4 as run: ffmpeg -v error -y -i video.mp4 -t 3 -vf "subtitles=Ep 1: Intro.srt:fontsdir=fonts-fix:force_style='FontName=Inter'" -c:a copy burned4.mp4; echo first-exit=$?; ffmpeg -v error -y -i video.mp4 -t 3 -vf "subtitles=ep1.srt:fontsdir=fonts-fix:force_style='FontName=Inter'" -c:a copy burned5.mp4 && ffprobe -v error -show_entries format=duration -of csv=p=0 burned5.mp4 [Parsed_subtitles_0 @ 0x5a9b3c74c980] Unable to parse option value "Intro.srt" as image size Error applying option 'original_size' to filter 'subtitles': Invalid argument [vost#0:0/libx264 @ 0x5a9b3c523e00] Error initializing a simple filtergraph Error opening output file burned4.mp4. Error opening output files: Invalid argument first-exit=234 3.015000 exit=0 done