[MPlayer-users] Reading DVD Title as String, possible?

Reimar Döffinger Reimar.Doeffinger at stud.uni-karlsruhe.de
Sat Aug 30 10:21:11 CEST 2008


On Sat, Aug 30, 2008 at 12:14:38AM -0400, Alex Sherwin wrote:
> However, what I didn't expect to run into as a roadblock is that I can't get
> the DVD Title as a String out of MPlayer.

Try attached patch. But note that the title as stored on the DVD is
usually quite ugly.

> There's no mention of ID_DVD_DISC_ID
> in any docs, and Google doesnt give anything but dump's of people running
> MPlayer...

I think the idea was to use it for services similar to CDDB for CDs, but
it seems there is not a single one that uses it...

> Any help you can give is greatly appreciated...  I would like to avoid
> having to modify mplayer source and compile a new executable to print out
> this info, but if that's what it comes down to... any information on where
> to look, and how to compile it for Windows would be great.

There should be a howto for that. Or give it a try on Linux (in a VM or
whatever) where it should be a lot easier (though still not trivial if
doing it for the first time). Linux also has e.g. lsdvd that shows this
information (maybe it exists for Windows as well?).
Otherwise hope the patch makes it in SVN soon and then get a precompiled
binary from one of the "related projects" pages.

Greetings,
Reimar Döffinger
-------------- next part --------------
Index: stream/stream_dvd.c
===================================================================
--- stream/stream_dvd.c	(revision 27489)
+++ stream/stream_dvd.c	(working copy)
@@ -860,6 +860,7 @@
     }
     if (mp_msg_test(MSGT_IDENTIFY, MSGL_V))
     {
+      char volid[32];
       unsigned char discid [16]; ///< disk ID, a 128 bit MD5 sum
       int vts_no;   ///< video title set number
       for (vts_no = 1; vts_no <= vmg_file->vts_atrt->nr_of_vtss; vts_no++)
@@ -872,6 +873,8 @@
           mp_msg(MSGT_IDENTIFY, MSGL_V, "%02X", discid[i]);
         mp_msg(MSGT_IDENTIFY, MSGL_V, "\n");
       }
+      if (DVDUDFVolumeInfo(dvd, volid, sizeof(volid), NULL, 0) >= 0)
+        mp_msg(MSGT_IDENTIFY, MSGL_V, "ID_DVD_VOLUME_ID=%s\n", volid);
     }
     /**
      * Make sure our title number is valid.


More information about the MPlayer-users mailing list