Grab vtt subtitles from m3u8 stream
Solution 1
Try this program: m3u8x
m3u8x is to help you download and save m3u8-subtitle(.vtt), and convert to (.srt).
Copy the M3U8 file and then paste its file link to m3u8x... and click download
The product link also includes a tutorial.
Solution 2
I know that the post is old, but here is a ffmpeg
solution as you asked for.
ffmpeg -i 'https://example.com/link/to/subtitles_playlist.m3u8' subtitles.srt
Solution 3
I would also suggest an ffmpeg solution, but with a different script:
ffmpeg -user_agent "Mozilla/5.0 (Windows NT 10.0; rv:78.0) Gecko/20100101 Firefox/78.0" -referer "about:blank" -i "https://example.com/link/to/subtitles_playlist.m3u8" -c copy "subtitle_eng.vtt"
Then convert the downloaded .vtt file to .srt (by Subtitle Edit for example)
Related videos on Youtube
![Yehor](https://i.stack.imgur.com/SIurX.png?s=256&g=1)
Yehor
Updated on September 18, 2022Comments
-
Yehor almost 2 years
I have a video stream http://content.uplynk.com/ext/6790c94a453741799d3f3fb3bc9023a4/2493079.m3u8 which can be perfectly grabbed by ffmpeg command
ffmpeg -i "http://content.uplynk.com/ext/6790c94a453741799d3f3fb3bc9023a4/2493079.m3u8" -c copy CMA.ts
In this m3u8 list there is a subtitles stream http://content-aeui1.uplynk.com/395e08dcb0b54a3781d34d0b840df075/sub3.m3u8 , which has several vtt parts.
Is there a way to grab those vtt parts into single vtt file and then convert to some common format like srt ?
Or maybe there is a way to grab video with subtitles embedded?
-
Yehor about 7 yearsThanks, it seems to be really working, I got a single .srt file finally !
-
Mundi over 3 yearsI had the subtitle URI (in the master
.m3u8
file) as a single file name, so I got the error message "Can't support the subtitle". But the above command with the original URL with the subtitle file name substituted worked. -
YourMJK over 3 yearsThis worked for me! I opened the master.m3u8 file, found the line beginning with
#EXT-X-MEDIA:TYPE=SUBTITLES,GROUP-ID="subtitles-0",NAME="English"
and used the following URI as theffmpeg
input.