How to determine main movie DVD track before ripping via mencoder

1

Maybe there's a simple answer for this, but when looking at the files on a DVD (IFOs, VOBs,etc), is there a way to easily determine the longest/main track? I'm trying to automate the process of finding the main movie track on a DVD and am running into issues.

I thought this could be done by finding the BIGGEST track (look through VTS_XX_N.VOB files, where XX is the track number, and find the track with the largest filesize (sum sizes of VOB files for that track)), but apparently that isn't correct. One DVD had track 7 as the largest track (by my method), but mencoder didn't produce the correct output with this track, but worked with track 9 instead.

Am I missing something?

EDIT: I've heard of the utility 'lsdvd' for getting track information, but I was hoping to avoid compiling this, and use a basic method instead (ie: what I tried above). Does anyone have any idea WHY my idea didn't work?

Ampp3

Posted 2012-12-13T06:23:15.250

Reputation: 111

Answers

0

I ended up just using mplayer -identify to get the lengths of each track, identifying the longest, and working with that track. While this method doesn't work 100% of the time (especially with certain DVD protection mechanisms), it worked great for what I was doing. Here's my final command I ended up using:

mplayer -dvd-device e: -nocache -identify dvd:// -vo NUL -ao NUL -frames 0

Ampp3

Posted 2012-12-13T06:23:15.250

Reputation: 111

1

If you don't mind doing one extra step in your process, you can have a look at lsdvd, a command line program which lists the content of a DVD, including the track lengths.

user1301428

Posted 2012-12-13T06:23:15.250

Reputation: 2 985

I've heard about this utility before, though I didn't want to worry about trying to compile it if there was an easier way to just figure out the track, with something like my method. I was also secretly hoping that my issue was due to some sort of bug with mencoder :) – Ampp3 – 2012-12-13T13:58:21.523

@Ampp3 Unfortunately I don't know if mencoder can show such information... – user1301428 – 2012-12-14T11:42:58.193

Mplayer, or maybe mencoder, can show track info, but it doesn't appear to be correct... Maybe I do just need to compile lsdvd – Ampp3 – 2012-12-14T16:28:08.500