Mitigating the issue of burning in a subtitle (encoding)

HandBrake for Mac 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.
Post Reply
mike548141
Posts: 26
Joined: Mon Nov 08, 2010 5:02 am

Mitigating the issue of burning in a subtitle (encoding)

Post by mike548141 »

Hi All,

My Commentary
I enjoy good quality AV and I'm a little OCD at times.... Some friends call me ISO Mike, others call me names probably not suitable to write here.
I'm no audiophile / AV specialist but after literally years (bouts of dedication with big gaps) of testing encodes, trawling the web and HB forums I feel Handbrake is now at the feature level I want, and I think I have a pretty good group of settings (happy to share them if anyone wants them).

One of my goals to is to "digitise" my library, separating the content from the medium. I prefer to keep more content and quality at the sacrifice of storage/network utilisation so I:
- Pass thru all audio tracks (all languages) in their native format (AC3 and DTS.), plus the feature track in AAC. P.S> Wouldn't it be great if HB passed thru the track title e.g. "Director's Commentary".
- Pass thru all subtitle tracks (all languages).
- The settings I use seem to mitigate issues with AV sync (aka Lip Sync) and getting a decent image out of the MPEG2 to MPEG4 (H.264) conversion.

My Question:
The issue I have is burning in the "Foreign Audio Search" subtitle track, sure I want it to appear by default but I don't want it burnt into the video track i.e. unable to remove/disable. Does anyone have any smart ideas to get around this?

Note I'm mainly still working with DVD media @ 720p, as I move forward I hope that it will translate to Bluray without to much tweaking. Also playback wise I'm mainly using ATV v2, iPhones, Mac's, Windows with VLC etc...

A preemptive Thanks for your helpful thoughts and feedback,

MC
tdtran1025
Posts: 20
Joined: Thu Jul 15, 2010 9:15 pm

Re: Mitigating the issue of burning in a subtitle (encoding)

Post by tdtran1025 »

It's not as simple as upgrading to a bluray title. Subtitle in bluray is entirely a different format.
Look elsewhere in this forum for procedure. Here is how the process works in brief:
-After the movie has been ripped to mov format, extract the PGS subtitles. This is the most difficult process involving terminal commands because there's not a GUI base program yet. MkvToolnix for mac still lacks this demux feature, which is a glaring omission. Yet before extracting the tracks, you would have to know what tracks they are, which means you have to use the following step before this.
-Use Mkvtoolnix to identify all PGS tracks (subtitles). PGS stands for presentation graphics stream. Then go back to previous step to manually key in tracks.
-Use BDs2s, a java script to convert all extracted substitles to idx format that syncs with frame.
-Then go back to MkvToolnix to remux new tracks to main movie while taking out all PGS tracks.

If this sounds like a nut job, it is. Going from DVD to bluray messes up subtitle in a big way.

There is an easier way, but it involves searching for de desired subtitle in art format online. The try to play the movie with the downloaded subtitle to check for sync. Then HB can incorporate such subtitle with ease.
If there's a simpler or better process out there people know about, I will stand to be corrected.
Good luck with it
mike548141
Posts: 26
Joined: Mon Nov 08, 2010 5:02 am

Re: Mitigating the issue of burning in a subtitle (encoding)

Post by mike548141 »

Hi tdtran1025,

Thanks but I don't see how your response really applies to my question i.e.
"The issue I have is burning in the "Foreign Audio Search" subtitle track, sure I want it to appear by default but I don't want it burnt into the video track i.e. unable to remove/disable. Does anyone have any smart ideas to get around this?"

Basically I want to grab the foreign audio track (forced or auto-detected by HB) and store it as a separate track in the MP4 container. The trick is I want it to display by default on ATV without burning it into the video.

RE Bluray subtitles. When I start doing more with Bluray media I plan to use SRT's unless things change in a big way. A plain text format makes a lot of sense to me, just wish it was the default in DVD media.

Cheers,

MC
Smithcraft
Veteran User
Posts: 2691
Joined: Thu Jan 22, 2009 8:04 pm

Re: Mitigating the issue of burning in a subtitle (encoding)

Post by Smithcraft »

The problem with forced subs is that the studios don't follow any sort of standard in implementing them.

Sometimes forced subs are a subset of the primary subtitle stream with individual images being flagged as forced, and sometimes they are a different stream where the whole stream is flagged as forced.

If you don't want them burned in then don't select the burn in option.

Also, what you want overall do, isn't really advisable with the MP4 container, as there is not much that will play DTS in that container. So when you move on the HD sources, you will find that majority of the audio is in DTS.

SC
mike548141
Posts: 26
Joined: Mon Nov 08, 2010 5:02 am

Re: Mitigating the issue of burning in a subtitle (encoding)

Post by mike548141 »

The problem with forced subs is that the studios don't follow any sort of standard in implementing them.
Yeah I have read the various write ups on what HB has to do to work around the industries failings.
If you don't want them burned in then don't select the burn in option.
The problem is then I find many devices/apps don't display the default subtitle track. i.e. either I a) burn in and and I get subtitles that work but I can never get rid of or b) don't burn in and the foreign language subtitles don't show up. My ideal solution is the foreign language subtitles detected by HB are saved to a separate track (like all the other VOBSUB tracks) but in a way that they are displayed by default.
Also, what you want overall do, isn't really advisable with the MP4 container, as there is not much that will play DTS in that container. So when you move on the HD sources, you will find that majority of the audio is in DTS.
Sorry I'm not sure I understand this sentence. Are you saying that there is not much pont in passing thru the DTS tracks because there are not many devices that will play it from a MP4 container currently?
I have had no issues (so far) with passing thru all the tracks from the DVD to a MPEG4 container (incl AC3 & DTS). Playback has been working well too.

Thanks,

MC
hanumang
Posts: 45
Joined: Thu Feb 04, 2010 6:11 pm

Re: Mitigating the issue of burning in a subtitle (encoding)

Post by hanumang »

mike548141 wrote:The issue I have is burning in the "Foreign Audio Search" subtitle track, sure I want it to appear by default but I don't want it burnt into the video track i.e. unable to remove/disable. Does anyone have any smart ideas to get around this?
Since you're posting this in the Mac forum, I'm hoping your actually using Mac OS X. If that is correct...

For your subtitles to behave in the way you're hoping, use Subler and its Forced Subtitle Track function (new in 0.17), instead of HandBrake. I haven't ripped a DVD this since functionality was introduced, so I have no insight into the specifics of the process for you.
Smithcraft
Veteran User
Posts: 2691
Joined: Thu Jan 22, 2009 8:04 pm

Re: Mitigating the issue of burning in a subtitle (encoding)

Post by Smithcraft »

Yes, you can include DTS in an MP4, but most stuff won't play it. Make sure that what you are playing it with, is playing the DTS track and not the AC3 track.

SC
mike548141
Posts: 26
Joined: Mon Nov 08, 2010 5:02 am

Re: Mitigating the issue of burning in a subtitle (encoding)

Post by mike548141 »

@hanumang
Since you're posting this in the Mac forum, I'm hoping your actually using Mac OS X. If that is correct...
Actually I am all over the show, most of my computers are Mac OS X but I also have a little Unix, some NetWare, a few Linux and a couple of Windows. All depends what is best for the job at hand.
For your subtitles to behave in the way you're hoping, use Subler and its Forced Subtitle Track function (new in 0.17), instead of HandBrake. I haven't ripped a DVD this since functionality was introduced, so I have no insight into the specifics of the process for you.
Excellent thank you, I will try that out this weekend. If that works then I owe you a beer! I assume that I should keep "Forced Only" and "Default" ticked in HB on the "Foreign Audio Search" subtitle track?

@Smithcraft
Yes, you can include DTS in an MP4, but most stuff won't play it. Make sure that what you are playing it with, is playing the DTS track and not the AC3 track.
Yeah my receiver specifies what it is decoding.

Thanks,

MC
mike548141
Posts: 26
Joined: Mon Nov 08, 2010 5:02 am

Re: Mitigating the issue of burning in a subtitle (encoding)

Post by mike548141 »

@hanumang - I have tried the Forced Subtitle option in Subler (version 0.17) without luck.

To test it I took an ISO file of a movie and encoded it using HB (pass thru all audio tracks and all subtitle tracks). On the "Foreign Audio Search" subtitle track I ticked "Forced Only" and "Default" and un-ticked "Burned In". In Subler, MediaInfo Mac and VLC I can see the 5 VobSub subtitle tracks (1 track for "Foreign Audio Search" and 4 tracks from the DVD) in the m4v file.

In Subler I chose an enabled (ticked) subtitle track and I set "Forced" to "All Samples Are Forced", I also set "Forced track" to "Track 9". I pressed save and Subler appeared to save normally however once it had completed saving the "Forced" and "Forced Track" options had reset to default ("No" and "None").
Play back on this file also does not show any subtitles by default using iTunes, ATV or VLC, opening the file in Subler again also shows the forced settings have not saved. If I play the file using VLC then I can chose to display any of the 5 subtitle tracks.

Has anyone successfully used this option in Subler? It shounds like exactly what I want but it does not appear to work yet (unless its me/my equipment/my configuration).

Note on the ATV if I hold down the selection button during a movie I do get the Chapter list with preview images and a list of alternate audio tracks but I do not get a list of subtitle tracks.
In the ATV settings (Settings -> Audio & Video -> Subtitle Language) Subtitles are set to English and Closed Captions are set to On.

All encoding/testing on
- Mac OS X 10.8.2
- Handbrake 0.9.8 x86_64 (2012071800)
- iTunes 10.7 (21)
- VLC 2.0.3
- Apple TV 2nd generation, running firmware 5.1 (5201)
- All media containers are MPEG4 and use the file name extension ".m4v". H.264 (x264) codec used.

Thanks

MC
User avatar
Rodeo
HandBrake Team
Posts: 12569
Joined: Tue Mar 03, 2009 8:55 pm

Re: Mitigating the issue of burning in a subtitle (encoding)

Post by Rodeo »

Sounds like it might be a Subler bug?

http://code.google.com/p/subler/issues/list
mike548141
Posts: 26
Joined: Mon Nov 08, 2010 5:02 am

Re: Mitigating the issue of burning in a subtitle (encoding)

Post by mike548141 »

Hi Rodeo,

Could be, I have logged a issue with Subler (http://goo.gl/3OALt)

Cheers,

MC
mike548141
Posts: 26
Joined: Mon Nov 08, 2010 5:02 am

Re: Mitigating the issue of burning in a subtitle (encoding)

Post by mike548141 »

Ok looking into this further it seems the only way I can achieve this goal (and be able to play back subtitles on most/all devices) is to
1) Get the VobSub subtitle track I want to embed (from an existing MP4 or a DVD)
2) Use the timing queues from the extracted VobSub track to create a tx3g track (or maybe SRT) that appears at the correct points in the movie
3) Use an OCR engine like tesseract-ocr (http://goo.gl/qU9lt) to convert the VobSub bitmap images of text into editable text
4) Save that text into the tx3g track, at the correct timing queues.

In other words do-able, but a bit of a bugger.
Out of interest does anyone know if the HB crew have published anything that defines the scope of HB as they see it? For example obviously re-encoding video and audio is considered in-scope for HB, but (from what I have read) integrating meta-data is considered out of scope.

Thanks,

MC
User avatar
Rodeo
HandBrake Team
Posts: 12569
Joined: Tue Mar 03, 2009 8:55 pm

Re: Mitigating the issue of burning in a subtitle (encoding)

Post by Rodeo »

The scope of HandBrake might be:

1) something that someone is interested in and provides a decent patch for

AND

2) something that is not a pain to maintain

AND

3) something that can be added to the UIs without too much trouble

…at least that's how I see it.
User avatar
s55
HandBrake Team
Posts: 9805
Joined: Sun Dec 24, 2006 1:05 pm

Re: Mitigating the issue of burning in a subtitle (encoding)

Post by s55 »

Just wanted to point out that tesseract-ocr is not GPL v2 compatible.
mike548141
Posts: 26
Joined: Mon Nov 08, 2010 5:02 am

Re: Mitigating the issue of burning in a subtitle (encoding)

Post by mike548141 »

@s55 - Yeah its Apache v2.0 so its only compatible with GNU GPL v3.

Is there a way to have the "Foreign Audio Search" subtitle track extracted twice? i.e. on two separate tracks, each with different settings.
Currently the GUI only allows me to select "Foreign Audio Search" on the first subtitle track.

Cheers,

MC
Post Reply