Subtitles

This is a very deep subject - so we will skim the top and show you what you need.

Subtitles are similar to "Captions" - they display text at the bottom of the screen that follows the words being spoken on the video.  The most common application is for foreign films - the subtitles let you see the works in English.  Subtitles are a separate stream of data that is combined with the Video stream.  They can have just one language or they can come in multiple languages - i.e. multiple streams.

Subtitle FileTypes

There are many formats of subtitle files, each is designated by the file extension.  The most common are SUB/IDX,.SRT, SUP, and SSA.  Ther is also SMI, TXT, and about 20 others.

If you have a "sub" file then you also need the corresponding "idx" file - the sub file in compressed text for the words, and the idx file is a text file containing the timings and synchronization of the words (i.e. it tells the media player "when" to display each set of words).  The other file types are all singular - just one file contains all the necessary data.

When downloading movies on the Web where you have the movie file with no subtitles and then a separate subtitles file - there are two ways to view them on your PC - you will need to test and use trial and error to see what works best for you and your video card.  Subtitles are very very picky and often do not work unless in a particular format:

  1. Create a Hardcoded subtitle AVI - combine the subtitles with the video - these are called "Hardcoded" subtitles - and watch the movie on any media player and then either watch it on your computer screen or send it to your TV via a TV Out port on your video card.  I use the method outlined below using SSA files - if I have an SRT file I synch it using Subtitle Workshop but save it as an SRT because the SSA files from that app don't work for me.  Then I convert the SRT using SRT-to-SSA and then use the Virtual Dub method below to combine the SSA stream with the AVI video stream, creating ba new AVI with hardcoded subtitles.

    NOTE:  supposedly the Media Player Subtitled Media Player - "DVlaD" ( http://users.pandora.be/vlad/subsync/dvlad.htm ) will play a wide variety of subtitles. 
     
  2. Play separate video/subtitle Streams - open both files in a media player that supports separate video and subtitle tracks, and play the movie with the subtitles being dynamically sent to the screen.  You can use a player such as VLC (but don't - it is terrible with subs) which will auto-detect the subtitles track, then start the movie and select Video/Subtitles . . . Track1.  But VLC often misses words or even entire sentences.  The better way is to install a Direct Show filter called VobSub which will apply the subtitles into any DirectShow capable video player.  It works best with WMplayer and Media Player Classic (MPC).  It will autodetect the subtitles track but so far it ONLY works with SUB/IDX file pairs for me !!  In all cases the names of the files MUST be IDENTICAL EXCEPT FOR THE FILE EXTENSION !!!

Downloaded Movies (from Bit Torrents)

Creating Subtitle Files from DVD's - for Uploading to Bit Torrents

There are numeropus ways to do this - all of them a hassle.  You can use "SubRip" to pull the subtitles off the VOB files from the DVD, then convert the main movie to an AVI and test the synchronization using Subtitle Workshop and adjust if necessary ( usually it is necessary).

Adding SSA subtitles to any .avi file


Here is a quick and simple guide to add SSA subtitles to any .avi file that you would like to have harcoded subtitles.  Here are the tools needed:

VirtualDUB         SRT-SSA Converter (if you have SRT instaed of SSA)        VirtualDub Subtitler Plug-in       DivXLand Media Subtitler 

Copy the VirtualDub plugin "subtitler.vdf" into the PLUGINS folder under the VirtualDub program directory - the filter will then automatically load when
the main program starts. If the PLUGINS folder does not exists, create it.

Synchronize the Subtitles if Necessary - start up Subtitle Workshop or use SubSynch.  Load the movie into the preview pane, then load the subtitle file - preferably in SRT format.  Play a few sements and check the synchronization of the audioble spoken words with the subtitles flashing on the bottom of the video.

What is the Best Timing to Use ??   The words of a sentence should pop up onto the screen either "exactly" when the speaker says the first word, or after a brief delay (about 1/2 sec into the spoken sentence).  Do NOT have the subtitles pop up BEFORE the first word of the sentence is spoken - that just "feels uncomfortable" as you watch the movie.

Convert your Subtitles File into SSA Format - the VirtualDub subtitle filter works with ssa subtitles ONLY.  So if you have the more common sub or srt or some other format, you will need to convert it to ssa. 

Naming Convention -  although not always necessary, to create a good habit - name the subtitle file the same as the movie.  For example, if the movie file is "Miami Vice 2006.avi" then name the subtitle file "Miami Vice 2006.ssa"

Customize the Subtitles (color, font, placement) - even if your subtitles are already in SSA (SubStation Alpha) format, this step is recommended to customize the subtitles aspect. We'll use DivXLand Media Subtitler to convert the subtitles to SSA and/or edit their font aspect and position. Open the subtitles with DivXLand Media Subtitler from the File menu.

Then go to Settings > Format Settings. In the popup dialog select the SubStation Alpha format.

 

Configure the format with a clear font such as Trebuchet MS and a font size of 36pt. Here you can also change the subtitles alignment and margins if desired.

After that you can save the subtitles from File > Save As. The following dialog will popup:

Make sure to select the SubStation Alpha [SSA] format and click OK to save the subtitles.

Converting subtitles


The next step is converting the .srt files into something VirtualDub can read, in this case, an .ssa file.

Open up the .SRT-.SSA Converter and click on Browse to select the .srt file you want converted.

The program will now automatically create an output file with the identical name as the input file except with an .ssa extension.

All you have to do now is hit Convert and wait until it is done processing.


Adding subtitles into VirtualDub


[img right]http://i.afterdawn.com/articles/adding subtitle.PNG[/img]Its now time to go back to VirtualDub which should still be open.

Go to the Video tab and select "Full Processing Mode". Then under Audio select "Direct Stream Copy" (it will usually be set to that already).

Now go to File and Open Video File... and use the browse function to select the .avi file you want the subtitles hardcoded to. Press Open when you find it.

Once the video has opened, go once again to the Video tab and select Filters again.

Press the Add button, and navigate down to the Subtitler option and press OK.

Select the .ssa you created earlier and press OK


Selecting the Compression


The final step is selecting the compression for our .avi.

Navigate once again to the Video tab and this time press on Compression.

If your file is an XviD (most will be) then simply select XviD Mpeg-4 Codec from the list. Leave the default settings.

If your file is another type of compression select that from the list and leave the default settings.


Saving your file and finishing up


To finish up simply go to File and select Save As .avi or simply press F7 for convinience. Save it where you want and make sure the Save as type is set to audio-video interleave (avi).

Click Save and you are done. Sit back and wait for your .avi with hardcoded subtitles.