User Tools

Site Tools


howto:subtitles

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
howto:subtitles [2025/02/01 22:44] Wulf Rajekhowto:subtitles [2025/07/09 16:31] (current) Wulf Rajek
Line 18: Line 18:
 </code> </code>
  
 +===== Alternatives =====
  
 Untested alternative without limitations: Untested alternative without limitations:
 https://github.com/kaegi/alass https://github.com/kaegi/alass
 +
 +Other alternative:
 +https://snapcraft.io/subsync
 +https://sc0ty.pl/
 +https://subsync.online/
 +https://github.com/sc0ty/subsync?tab=readme-ov-file
 +
 +
 +https://github.com/denizsafak/AutoSubSync
 +
 +===== Yatse kodi offset =====
 +
 +JSON-RPC
 +Method: Input.ExecuteAction
 +Parameter:  {“action”:“subtitledelayminus”}
 +or
 +Parameter:  {“action”:“subtitledelayplus”}
 +
 +
 +===== Extract subtitles =====
 +Extract subtitle with specific metadata title:
 +<code>
 +for f in *.mkv; do ffmpeg -hide_banner -i "$f" -c copy -map 0:s:m:title:"English [ForcedNarrative]" "${f%.*}.en.forced.srt"; done
 +for f in *.mkv; do ffmpeg -hide_banner -i "$f" -c copy -map 0:s:m:title:"angličtina" "${f%.*}.en.srt"; done
 +
 +#extract 2 at once
 +for f in *.mkv; do ffmpeg -hide_banner -i "$f" -c copy -map 0:s:m:title:"English [ForcedNarrative]" "${f%.*}.en.forced.srt" -c copy -map 0:s:m:title:"angličtina" "${f%.*}.en.srt"; done
 +</code>
 +
 +===== Set subtitle to forced =====
 +This copies the video and audio stream of an mp4 file, sets the first mov_text subtitle stream to 'forced' and the second to normal:
 +<code>
 +ffmpeg -i input.mp4 -vcodec copy -acodec copy -map 0:v:0 -map 0:a:0 -map 0:s:0 -c:s mov_text -disposition:s:0 forced -map 0:s:1 -disposition:s:1 0 output.mp4
 +</code>
 +
 +For mkv files, this probably needs to be srt instead of mov_text.
  
howto/subtitles.1738449883.txt.gz · Last modified: by Wulf Rajek