I want to convert audio/video file to SRT. I've tried these commands:
ffmpeg -i sample.mp4 sample.srt
ffmpeg -threads 4 -i sample.mp4 -vn -an -codec:s:0.2 srt sample.srtBut then I learned that it was for extracting the subtitle from already subtitled videos. Is there a way I can generate subtitles from mp4/mp3 files?
Thanks in advance!
2 Answers
You need a tool that does speech-to-text and creates as subtitle file. This is a very specialized operation.
See the articleHow to Generate Subtitles for Audio and Video? [9 Best Tools]for a list of websites and tools, where the first in the list is YouTube.
2As far as I know ffmpeg alone does not support speech recognition.
There are some other tools to do that, like Autosub.