How to hard code subtitles to a video from Youtube
I have been playing around with computers for some time. Yet, every time I have to deal with video files, I feel embarrassed about my ignorance. Last time I checked, DivX and Xvid were the hot stuff. Nowadays, things are more complicate. There are flv videos, sub and ssa subtitles, and more acronyms I could imagine.
A customer recently asked me to get some video from YouTube, translate them in Italian, add subtitles, and upload them on their YouTube channel. Not a big deal. YouTube accepts captions in Subviewer and Subrip formats. The problems is we don't necessarily want to rely on YouTube (related video? captions?).
So we decided the best way was to hard code subtitles in the video files, so they would always show no matter what player was in use. I took some time to research, as there are several video and caption formats, and even more way to convert them. I wanted a straight forward procedure to put together the FLV video with the caption file doing the least amount of conversion.
What follows is, I hope, a fool proof step-by-step procedure. It may no be the best way to procede, but it worked for me. At the bottom I include a list of guides and how-tos from which I got precious informations.
How to hard code subtitles to a YouTube video
Preparation:
- download and Install Virtualdub from http://www.virtualdub.org
- download and install subtitler filter from http://www.virtualdub.org/virtualdub_filters
- download and install flvinput plug-infrom http://moitah.net/ (follow the directions on the site, including the instructions regarding ffdshow-tryouts)
- download and install VobSub from http://www.divx-digest.com/software/vobsub.html. All it's actually needed is SubResync (make sure to install it) to convert subtitles from srt to ssa
Procedure:
- create the captions file. A very good tool is http://captiontube.appspot.com (You don't need to own the video, it's enough to provide the url)
- download the caption file (.srt). Open it with SubResync (part of VobSub) and save it as ssa file. Some guides reccomend using SRT to SSA converter. Unfortunately, it didn't work for me.
- download the flv from YouTube. There are many way to do this, the easiest I found is the Download Helper addon for Mozilla Firefox http://www.downloadhelper.net
- start Virtualdub and open the .flv file (file->open video file)
- go on video->filters and click the add button. Scroll the list and locate subtitler. Click OK.
- a dialog will open. Locate the .ssa file created in step above. Select the appropriate word wrapping option (a preview is available)
- go on video->compression to pick an output format. This will determine the outcome quality of the video, as well as the time required for the encode operation. In my case, VP2 (set to 1 pass best quality) worked fine
- go on file->save as avi, name your file and click save. Virtualdub will do the magic and produce a file with hard coded subtitles. Leavining the show options unchecked may speed up the process a little bit
Interesting and helpful Links:
- Adding subtitles to any .avi file
- How To Combine Subtitles to Avi
- SBV file format documentation and converter
- Permanent Subtitles Guide


Comments
Works great
I used this method to add .SRT subtitles to an AVI file, worked great. I was a bit confused downloading the VobSub software, there are numerous files to choose from - you have to get the "VobSub_2.23.exe" file. Apart from that, thanks for a good guide.
I would like to say thank you
I would like to say thank you to author of these articles on this site. I read all of these articles and i need to read some new articles. I've watched a video on youtube about this topic for now and i loved it. Also it is one of the rarely topic on this site.
See you on a new topic...
Post new comment