HOWTO:Blu-ray "Forced" Subtitles-Avatar, District 9, etc...

HandBrake for Windows support
Forum rules
An Activity Log is required for support requests. Please read How-to get an activity log? for details on how and why this should be provided.
Destaas
Posts: 4
Joined: Thu Jun 10, 2010 9:36 pm

HOWTO:Blu-ray "Forced" Subtitles-Avatar, District 9, etc...

Post by Destaas »

Hey all,

If you're like me, you want 720p or above video, DD 5.1 or above audio and when there is something specific that needs to be subtitled...it too! Examples woud be the Na'vi language parts of Avatar, the alien language parts of District 9, etc...I'm not interested in Closed Caption or anything else, just the certain subtitles that the director felt it necessary for me to see. ;-) The difficult part is that some are already "burned-in" while others, such as Avatar and District 9, you have to do yourself (maybe all the late-2009 and newer Blu-rays?).

I play all of this on my ATV (Apple TV) and don't want to worry about soft subs and making sure it's enabled each time I watch, so I choose to "burn" them in. These are the original fonts/sizes/positions, not the .srt/txt versions.

I have a process that works for me that I thought I would share as it seems there are only bits and pieces of the info available out there. Please do not consider this the only way to approach it as others exist (if not variations of the theme). If anyone has a more efficient way to do this, please speak up! The entire process takes about 8-12 hours although much of it is processing.

If this has already been posted, flame on! ;-)

Where the directions may not be too specific, refer to and match the screenshots.

You’ll need a few tools (I wish I could elaborate on how to configure and use each but there's not enough room in a single post):
1. ANYDVD HD (or equivalent Blu-ray ripper) – to rip the disc to your hard drive, unencrypted. http://www.slysoft.com/en/download.html
2. Clown_BD – to mux out your video, audio and subtitle tracks. http://www.clownbd.com/
3. BDSup2Sub – to create a track of just the “forced” subtitles. http://forum.doom9.org/showthread.php?t=145277
4. MKVMerge – to wrap this all into a pretty little package HandBrake can use. http://www.bunkus.org/videotools/mkvtoo ... loads.html
5. HandBrake – for the obvious reason ;-)

STEP #1 (RIP)
If using AnyDVD HD, simply insert your Blu-ray disc and select “Rip Video DVD to Harddisk”. If using something else, please refer to that product’s instructions. ;-)
Image


STEP #2 (Mux)
Open up Clown_BD and let’s start (de-)muxxing!
NOTE: I de-selected “Use tsMuxeR” and selected “Force Subtitles”
Image

In the next phase I select the Chapter, the Video, the DTS Master Audio (or TrueHD) and the English Subtitle. That’s it! If you feel you need more choices when it comes to encoding, feel free to choose some other options.

NOTE: I select AC3 at 640 as ultimately this will play from my ATV, feel free to choose something else if it works for you.
Click “Next” when you are ready to go. The process could take a bit (15-25 minutes usually for me).
Image

When this is complete, under the directory you chose in the beginning, you should see at least the following files:
1. Chapters_1.txt
2. Video_2.h264
3. Audio_3_English.AC3
4. Subtitles_9_English.sup
These names could vary, but they should be the only thing created in that directory since you started.

STEP #3 – (Get Your Forced Subtitles)
Launch BDSup2Sub and load the *.sup file you generated above.
Upon load, you are greeted with a conversion screen; the only thing I change is “FPS Target”. I type in “23.976” for my Blu-rays even though it is probably not necessary here (just to make sure).
Image

Click Ok and you’ll now see the main screen. You can adjust various things here but I keep it straight forward. In fact, double-check your output format in the menu bar.
Image

When ready, you’ll want to go to File and Save/Export, make sure to select “Export Forced Only” and click “Save”. I usually save this export back into my same working directory as mentioned above.
Image

STEP #4 – (Prepare It For HandBrake)
The tools you’ll need for this step all come in a package called MKVToolNix. This is where MKVMerge and MMG will be located. MMG is the GUI for MKVMerge.
Launch MMG.exe and open or drag the Video_2.h264 file, the Audio_3_English.AC3 file and the Subtitles_9_English_exp.idx file into the tool (your file names may vary here, but you want video, audio and the “exported” subtitles file or .idx extention).

When you open or drag in the video, you may get a pop-up warning. Close it and highlight the video file, move to the “Format specific options” Tab and make sure to enter the correct frames-per-second in the “FPS:” field, I again use “23.976” for my Blu-ray movies. NOTE: DO NOT FORGET THIS PART!

Choose your output filename in the “Output filename” field at the bottom and “Start muxxing”! (This too can take some time, generally 15-25 minutes for me).
Image

STEP #5 – (Encode!)
For HandBrake, I use the nightly builds and not the general release candidate (0.9.4). Your mileage may vary here, but you can actually install the nightly build version in a separate directory if you want to keep both.

Nevertheless, open your .mkv file you created in Step #4 and define your “Destination File:” (I always use the file extension .m4v and select "Large File Size")

I happen to have my own Preset created so I will show you the settings as I step through this. It is formatted for 720p with DD 5.1. It plays flawlessly on ATV and just as well on my XBOX Media Center (although you only get Dolby Surround with .mp4/.m4v). Many 720p movies I rip end up being between 4 and 8.5 GB.

Picture:
Image

Video Filters:
Image

Video:
Image

Audio: (I do specify the source for Track 2 as my (AC3) (5.1ch) selection. I do NOT use Automatic)
Image

Subtitles: (I specific my English track with “Force”, “Burned In” and “Default” selections, then click Add. "Default" may not be required.)
Image

Chapters: (No chapters for me, never cared) ;-)

Advanced: (For those interested, I believe this was based on the AppleTV preset from previous versions. I haven't changed anything intentionally)
Image

This encoding can take some time, usually between 5 and 10 hours for me depending on the movie itself.

Anyway, hope this helps someone. This quick guide may be less-than-perfect (and I did kinda throw it up here), so let me know what I'm missing!
nightstrm
Veteran User
Posts: 1887
Joined: Fri Mar 23, 2007 5:43 am

Re: HOWTO:Blu-ray "Forced" Subtitles-Avatar, District 9, etc

Post by nightstrm »

This is an interesting way to handle this, and with all the subtitle work that has been done lately, likely works very well. I'll have to give this a shot for the few Blurays I have with forced subtitles (Gran Turino, Iron Man), but does anyone know if 1) you can add a VOBSUB track to a .m2ts container, and if so 2) if Handbrake (nightly) will recongize a VOBSUB track in the .m2ts container?

Good thinking! If my testing goes well, I'll update my HDDVD/Bluray encodes thread in the Tiki Bar with a link to this thread (and info on how to fit it into the workflow outlined there).
Destaas
Posts: 4
Joined: Thu Jun 10, 2010 9:36 pm

Re: HOWTO:Blu-ray "Forced" Subtitles-Avatar, District 9, etc

Post by Destaas »

Thanks Nightstrm!

For those who want to visualize this, check out the screenshot below. (This was also the movie I used as my example in my guide)

Image

The key for me is that I can now re-encode this for multiple devices and not have to worry about subs displaying. ;-)
Deleted User 11865

Re: HOWTO:Blu-ray "Forced" Subtitles-Avatar, District 9, etc

Post by Deleted User 11865 »

nightstrm wrote:but does anyone know if 1) you can add a VOBSUB track to a .m2ts container
No idea.
nightstrm wrote:and if so 2) if Handbrake (nightly) will recongize a VOBSUB track in the .m2ts container?
No. HandBrake's TS and PS demuxers do not look for VOBSUB subtitles, assuming VOBSUB-in-TS is even possible (VOBSUB in PS is somewhat possible - VLC sees and display such subs even in standalone VOB files, but the palette is probably lost).

HB can only recognize VOBSUB tracks reliably (including the palette and width/height) from 3 types of sources: DVD file structures, MKV files and MP4 files.
nightstrm
Veteran User
Posts: 1887
Joined: Fri Mar 23, 2007 5:43 am

Re: HOWTO:Blu-ray "Forced" Subtitles-Avatar, District 9, etc

Post by nightstrm »

Rodeo wrote:
nightstrm wrote:but does anyone know if 1) you can add a VOBSUB track to a .m2ts container
No idea.
nightstrm wrote:and if so 2) if Handbrake (nightly) will recongize a VOBSUB track in the .m2ts container?
No. HandBrake's TS and PS demuxers do not look for VOBSUB subtitles, assuming VOBSUB-in-TS is even possible (VOBSUB in PS is somewhat possible - VLC sees and display such subs even in standalone VOB files, but the palette is probably lost).

HB can only recognize VOBSUB tracks reliably (including the palette and width/height) from 3 types of sources: DVD file structures, MKV files and MP4 files.
Thanks for the info... subtitles has always been one part of Handbrake that I haven't really paid much attention to. I guess I'll either modify how I prepare my Blurays for encoding, or wait and see what comes out of http://forum.handbrake.fr/viewtopic.php?f=4&t=16659 .
Deleted User 11865

Re: HOWTO:Blu-ray "Forced" Subtitles-Avatar, District 9, etc

Post by Deleted User 11865 »

Hopefully Blu-Ray structure support will also be added at some point.

If only John had unlimited time or something (wasn't there a astudent named John Stebbins in the Harry Potter books somewhere? - maybe he could help)…
plazapalz
Posts: 13
Joined: Tue Dec 30, 2008 5:57 am

Re: HOWTO:Blu-ray "Forced" Subtitles-Avatar, District 9, etc

Post by plazapalz »

Why not use MakeMKV and select "Forced Subtitles Only" during the rip. That way the video, audio, and forced subtitles are ready to go in the mkv container. Then you just extract your subs, change them to idx and mux 'em back. It's simpler and the only snag is that it does not convert DTS to AC3 for those planning on making mp4/m4v files.
Andymetro
Posts: 1
Joined: Mon Jun 14, 2010 12:02 am

Re: HOWTO:Blu-ray "Forced" Subtitles-Avatar, District 9, etc

Post by Andymetro »

I would just like to say thank you to Destaas. I searched and searched the net to try and find help for how to get the forced subs. This guide is almost perfect. Almost because the only way you can get the sub track to show is with using the nightly builds. 0.9.4 stable does not support this.

Thank You!
Destaas
Posts: 4
Joined: Thu Jun 10, 2010 9:36 pm

Re: HOWTO:Blu-ray "Forced" Subtitles-Avatar, District 9, etc

Post by Destaas »

Andymetro wrote:I would just like to say thank you to Destaas. I searched and searched the net to try and find help for how to get the forced subs. This guide is almost perfect. Almost because the only way you can get the sub track to show is with using the nightly builds. 0.9.4 stable does not support this.

Thank You!
Very cool! I'm glad it helped somebody. I was in a similar boat which was the reason why I thought I'd sit down and throw something together.

Thank you Andymetro!

-Destaas
upd
Posts: 2
Joined: Sat Jun 26, 2010 2:39 pm

Re: HOWTO:Blu-ray "Forced" Subtitles-Avatar, District 9, etc

Post by upd »

Destaas,

Thanks for writing up an outstanding HOWTO! I've been searching the internet far and wide on extracting the subtitles out of my BD Avatar disc. I've used Handbrake for converting movies for two years now and love it.

However, I've run into a little problem. After following your directions verbatim, Handbrake still does not recognize the VobSubs embedded in my Avatar.mkv. The only option I have is the silly "Foreign Audio Search" which does not yield burned in subtitles on my preview. I know the subtitles work correctly because they are displayed while playing the MKV file itself and they look like in the picture above where Norm is saying "May the All Mother..."

So here's what I've tried in mkvmerge with the VobSub track:
"Forced track flag" set to both "No" and "Yes"
Giving the track a name such as "Forced Subtitles (English)"
Setting the language flag to "eng (English)"

I have yet to set the "Default track flag" to "Yes." I am currently muxing the file one more time with that setting and I'll see what happens.


Any other suggestions? Maybe the preview function in Handbrake can't handle VobSub but if I were to do a complete file conversion they would be there?


-----EDIT-----
Right, nightly build. Just downloaded the latest (Windows) and I'm giving that a shot now. Thanks for the write up!
mkelley
Bright Spark User
Posts: 389
Joined: Fri Dec 25, 2009 2:00 am

Re: HOWTO:Blu-ray "Forced" Subtitles-Avatar, District 9, etc

Post by mkelley »

Let me post a somewhat simplified version of what this guy suggests and perhaps it will be easier to follow.

Encode the M2TS file with Handbrake as usual, in whatever way you normally like, to an MKV container (I use the High Profile and pass through DTS or AC3 tracks, but to each his own). Use tsMuxer to demux the PGS file from the M2TS file (this contains the subs). Use BDSup2Sub on the resultant file to convert to IDX (as noted in the steps above -- you choose "forced only" if that's all you want), and finally (simply) use mkvmerge to merge the Handbrake MKV with the IDX file created by BDSup2Sub.

The last three steps are *very* quick -- shouldn't take more than a few minutes on any decent machine. Obviously the first, Handbraked encoding will take a while (on my fast i7 it's usually about 2x as long as the movie on High Preset). To understand what you are doing in any of these routines, you are encoding the video and/or audio with Handbrake as normal, and then using demuxing and muxing tools to first remove the subs from the original and then put them back on your video/audio file (with the conversion to a format MKV understands taking place in the middle). Get it?
tazhombre
Posts: 2
Joined: Mon Jun 28, 2010 3:02 pm

Re: HOWTO:Blu-ray "Forced" Subtitles-Avatar, District 9, etc

Post by tazhombre »

Thanks for the How-To, worked brilliantly.

One side note on BDSup2Sub, in the instance of Avatar, as shown in the screencap above, the subtitle colors should be yellow but turned out cyan. I found to resolve this go to settings in BDSup2Sub and select Swap Cr/Cb, then save/export as normal. This will create a reversed color initially but then during handbraking it will revert to the original color.
Destaas
Posts: 4
Joined: Thu Jun 10, 2010 9:36 pm

Re: HOWTO:Blu-ray "Forced" Subtitles-Avatar, District 9, etc

Post by Destaas »

tazhombre wrote:Thanks for the How-To, worked brilliantly.

One side note on BDSup2Sub, in the instance of Avatar, as shown in the screencap above, the subtitle colors should be yellow but turned out cyan. I found to resolve this go to settings in BDSup2Sub and select Swap Cr/Cb, then save/export as normal. This will create a reversed color initially but then during handbraking it will revert to the original color.
Tazhombre, thank you! I followed your advice and re-encoded. Now I have the correct color as well.

-Destaas
tazhombre
Posts: 2
Joined: Mon Jun 28, 2010 3:02 pm

Re: HOWTO:Blu-ray "Forced" Subtitles-Avatar, District 9, etc

Post by tazhombre »

Destaas wrote:
Tazhombre, thank you! I followed your advice and re-encoded. Now I have the correct color as well.

-Destaas
You're welcome. It's great now being able to watch subtitled movies as intended, so thanks again!
nightstrm
Veteran User
Posts: 1887
Joined: Fri Mar 23, 2007 5:43 am

Re: HOWTO:Blu-ray "Forced" Subtitles-Avatar, District 9, etc

Post by nightstrm »

Just wanted to say that I finally got around to re-encoding the three Bluray discs that I have which use forced subtitles (Iron-Man, Gran Torino, Taken) and this method works beautifully. I did notice some issues with preview images (picture distorted, gray blocking) and auto-cropping not working, but I believe this is an ffmpeg issue as it only occurred when my source had h.264 video and was muxed into MKV via Mkvtoolnix. I plan on mentioning it on IRC when I have a chance, but I believe this is a known issue that also occurs in .9.4.
TedC
Experienced
Posts: 76
Joined: Sun Dec 13, 2009 1:44 am

Re: HOWTO:Blu-ray "Forced" Subtitles-Avatar, District 9, etc

Post by TedC »

I also would like to thank the OP on this guide - not only am I getting the burned in forced subtitles I needed (the soft subtitles were such a pain on Ubuntu/XBMC because for some reason - XBMC never remembered to show subtitles if they were there or not) - I can now embed chapters in the mkv using the mkvmerge application and handbrake picks them up and puts them into my final m4v.
jsmontgue
Posts: 1
Joined: Mon Aug 30, 2010 3:59 pm

Re: HOWTO:Blu-ray "Forced" Subtitles-Avatar, District 9, etc

Post by jsmontgue »

thanks so much for the guide! I've been trying to do this for a while now so i can have subs while i stream from WHS to xbox 360. Problem I have is after loading the mkv in clown i have subtitle (STR) English, Unspecified in my subtitles choices not the (PGS) like ur tut shows and it wont handle srt files. I tried converting the srt to sup with no luck, anyone else have this problem?
benchmarkjoe
Posts: 9
Joined: Thu Mar 25, 2010 12:15 pm

Re: HOWTO:Blu-ray "Forced" Subtitles-Avatar, District 9, etc

Post by benchmarkjoe »

mkelley wrote:Let me post a somewhat simplified version of what this guy suggests and perhaps it will be easier to follow.

Encode the M2TS file with Handbrake as usual, in whatever way you normally like, to an MKV container (I use the High Profile and pass through DTS or AC3 tracks, but to each his own). Use tsMuxer to demux the PGS file from the M2TS file (this contains the subs). Use BDSup2Sub on the resultant file to convert to IDX (as noted in the steps above -- you choose "forced only" if that's all you want), and finally (simply) use mkvmerge to merge the Handbrake MKV with the IDX file created by BDSup2Sub.

The last three steps are *very* quick -- shouldn't take more than a few minutes on any decent machine. Obviously the first, Handbraked encoding will take a while (on my fast i7 it's usually about 2x as long as the movie on High Preset). To understand what you are doing in any of these routines, you are encoding the video and/or audio with Handbrake as normal, and then using demuxing and muxing tools to first remove the subs from the original and then put them back on your video/audio file (with the conversion to a format MKV understands taking place in the middle). Get it?
Thanks MKelly, this one is also a very good way also. All I need to know now is how to change the fond size and style.
hp1
Posts: 1
Joined: Sat Sep 04, 2010 7:59 pm

Re: HOWTO:Blu-ray "Forced" Subtitles-Avatar, District 9, etc

Post by hp1 »

Let me post a somewhat simplified version of what this guy suggests and perhaps it will be easier to follow.

Encode the M2TS file with Handbrake as usual, in whatever way you normally like, to an MKV container (I use the High Profile and pass through DTS or AC3 tracks, but to each his own). Use tsMuxer to demux the PGS file from the M2TS file (this contains the subs). Use BDSup2Sub on the resultant file to convert to IDX (as noted in the steps above -- you choose "forced only" if that's all you want), and finally (simply) use mkvmerge to merge the Handbrake MKV with the IDX file created by BDSup2Sub.

The last three steps are *very* quick -- shouldn't take more than a few minutes on any decent machine. Obviously the first, Handbraked encoding will take a while (on my fast i7 it's usually about 2x as long as the movie on High Preset). To understand what you are doing in any of these routines, you are encoding the video and/or audio with Handbrake as normal, and then using demuxing and muxing tools to first remove the subs from the original and then put them back on your video/audio file (with the conversion to a format MKV understands taking place in the middle). Get it
Does this work for normal (non blu ray) MKV files. I'm trying to follow your post above but when I use Tsmuxer all i get are h264, aac and ac3 files, no idx.
Deleted User 11865

Re: HOWTO:Blu-ray "Forced" Subtitles-Avatar, District 9, etc

Post by Deleted User 11865 »

tsMuxeR only supports demuxing of Blu-Ray PGS subtitles.
DarkKnightWong
Posts: 3
Joined: Tue Sep 07, 2010 8:16 pm

Re: HOWTO:Blu-ray "Forced" Subtitles-Avatar, District 9, etc

Post by DarkKnightWong »

Ive been looking at your HOWTO.
I was wondering if anyone knows how to do this with MakeMKV.
Ive been using MakeMKV to rip all of my blu-rays and it has the PGS in the mkv it creates.
Is there away I can use mkv and create forced subs like this HOWTO ?

Thanks
Trevor68
Posts: 12
Joined: Thu Oct 07, 2010 6:28 am

Re: HOWTO:Blu-ray "Forced" Subtitles-Avatar, District 9, etc

Post by Trevor68 »

I'm wholly unsure, but I "think" that HB will not recognise the the bluray PGS format and you will still need to use this guide to get your forced subs?

Be good if someone cleverer than I could confirm this, as I too use MakeMKV and have often wondered if the PGS Forced subs it creates were useable or not???

I know that when I run HB on any of my MKV files all I see in the subs section is a Foreign Audio Bitmap.
Deleted User 11865

Re: HOWTO:Blu-ray "Forced" Subtitles-Avatar, District 9, etc

Post by Deleted User 11865 »

You are correct, HandBrake does not support PGS subtitles.
Trevor68
Posts: 12
Joined: Thu Oct 07, 2010 6:28 am

Re: HOWTO:Blu-ray "Forced" Subtitles-Avatar, District 9, etc

Post by Trevor68 »

Thanks, so I guess MakeMKV users still follow the above guide, but just use BDClown to take out the Forced PGS file, then load that into BD2sub and carry on from there then?
Trevor68
Posts: 12
Joined: Thu Oct 07, 2010 6:28 am

Re: HOWTO:Blu-ray "Forced" Subtitles-Avatar, District 9, etc

Post by Trevor68 »

Hey now this (and especially the commentary) is a REALLY interesting read.

http://www.mediasmartserver.net/2010/06 ... s-in-mkvs/

Seems PGS support may be becoming more commonplace eventually perhaps? It looks to me now as a FFDShow/Haali/MCE user all I need to do is configure properly and my MAKEMKV files with forced subs should work fine (i currently have directsubvob as default player).

Now how to handbrake those files without losing the PGS? or are they still there maybe? Mmm, I'll go check some files and see.
Post Reply