I have some video files containing HDMV PGS subtitles, and I need to convert them to subrip (or other text subtitles). I know that I can ffmpeg demux the video file to extract .sup
and on the fly convert it to VobSub, then subtitleedit /convert
that to subrip with its own tesseract.
However, I'd like to use only ffprobe/ffmpeg, which I have previously compiled with libtesseract and all. I don't mind parsing raw tesseract output into subrip either, but I just need to get it.
I've tried e.g.:
ffprobe -show_entries frame_tags=lavfi.ocr.text -f lavfi -i "movie=pgs.mkv,ocr"
Naturally, it tries to read the video stream instead of one of the subtitle streams. Aiming it at a .sup
file or multi-sub .mks
or .sub/idx
files gets me No video stream with index '-1' found
error, which is technically true, but...
is there a way to make ffprobe/ffmpeg OCR the actual subtitles instead of the video?