Assembling
Now we finaly reached the staged where we actually put together the final product and arrange all our datastreams into a structure.
A DVD comprises of one or more video title sets, abrevated VTS, that contain the video and audio information as data streams. Each disc can have up to 99 VTSes, and each title set can be subdivided into 99 chapters.
A titleset can contain a number of menus and titles which are meant to act together. All the titles and menus of a given titleset have the same video, audio, and subtitle settings so if you want to have different settings, for example widescreen vs standard aspect ratios, then you need separate titlesets.
Conceptually, a menu contains buttons which can be assigned actions and provides a list of choices to the end user, while a title contains the main content of the DVD. However, in reality many of the features available in menus — including buttons, pausing, and looping — are also available in titles.
An optional top-level menu known as the video manager menu, abrevated VMGM, is used to navigate between the different title sets. This is because titlesets are not meant to jump to one another. The VMGM is a collection of menus (no titles) that can access the menus and titles of all the titlesets.
First, a simple example of a DVD structure that forms the most basic DVD. The DVD player will start playing the movie when the disc is inserted and will stop at the end. Each chapter is put in it’s separate file.
<dvdauthor>
<vmgm />
<titleset>
<titles>
<pgc>
<vob file="chapter1.mpg" />
<vob file="chapter2.mpg" />
</pgc>
</titles>
</titleset>
</dvdauthor>
However this can be overridden using chapters=”foo”, the parameter is a comma separated list of timestamps of the form [[HH:]MM:]SS, making it possible to split up a single chapter into two files.
<dvdauthor>
<vmgm />
<titleset>
<titles>
<pgc>
<vob file="video1.mpg" chapters="0" />
<vob file="video2.mpg" />
</pgc>
</titles>
</titleset>
</dvdauthor>
Or it can be used to create create a movie with two chapters, one at the beginning (which is always required) and one five minutes into a single file.
<dvdauthor>
<vmgm />
<titleset>
<titles>
<pgc>
<vob file="video.mpg" chapters="0,5:00" />
</pgc>
</titles>
</titleset>
</dvdauthor>
Having a
<dvdauthor>
<vmgm />
<titleset>
<titles>
<pgc>
<vob file="video1.mpg" />
<post>
jump chapter 1;
</post>
</pgc>
</titles>
</titleset>
</dvdauthor>
One of the most frustrating things when deciding how to author a DVD is that there are often many ways to accomplish the same task. For example, you must decide whether to locate menus at the VMGM level or the titleset level. A typical setup is to locate the high level menus at the VMGM level, and the low level configuration menus (scene / audio / subtitle selection) at the titleset. If there are DVD extras, perhaps with a lower quality audio track and a 4:3 aspect ratio, then they would be in a separate titleset with a menu to select among the extras located at the titleset level.
To begin with a titleset can contain a menu and a title tag, while the vmgm block can only contain a menu.
A title or menu can contain video, audio, supbpicture and pgc tags. You should specify one video, audio or subpicture tag for each stream you multiplexed together. The title and menus of a given titleset must have the same settings. Most settings except language can be inferred from the source stream and do not need set manually.
The pgc block contain references to all video streams that make up that particular menu or title, including pre, post and button commands that alter how the streams will be played back. The pgc blocks of a menu can also be assigned to a key on the DVD players remote control, using the entry attribute, that playback will jump to when pressed during display of that particular titleset.
The following define a DVD structure containing one VMGM menu with two buttons, the first one will star playing the movie, the second will jump to a menu screen where a chapter can be selected.
<dvdauthor>
<vmgm>
<menus>
<video format="pal" aspect="4:3" />
<audio format="ac3" language="EN" />
<subpicture lang="EN" />
<pgc entry="title">
<vob file="mainmenu.mpg" />
<button name="1">jump titleset 1 menu entry root;</button>
<button name="2">jump titleset 1 titleset 1 title 1;</button>
<post>jump cell 1</post>
</pgc>
</menus>
</vmgm>
<titleset>
<menus>
<video format="pal" aspect="4:3" />
<audio format="ac3" language="EN" />
<pgc entry="root">
<vob file="chaptermenu.mpg" />
<button name="1">jump chapter 1;</button>
<button name="2">jump chapter 2;</button>
<button name="3">jump chapter 3;</button>
<button name="4">jump vmgm menu;</button>
<post>jump cell 1;</post>
</pgc>
</menus>
<titles>
<video format="pal" aspect="4:3" />
<audio format="ac3" language="EN" />
<audio format="ac3" language="SV" />
<pgc entry="root">
<vob file="chapter1.mpg" />
<vob file="chapter2.mpg" />
<vob file="chapter3.mpg" />
<post>jump menu entry root;</post>
</pgc>
</titles>
</titleset>
</dvdauthor>
To build the DVD structure on disk run dvdauthor:
$> dvdauthor -o test -x structure.xml
This will result in a test directory be created and in it a VIDEO_TS directory containing all files that make up the final DVD.
4 comments
Considering you’ve copied some of this from the Linux Journal article by Ian Pointer, you might consider attributing it properly.
Agreed, especially in view of the link to this page you’ve added in a comment to the LJ article!
Here’s is the link to the above-mentioned Linux Journal article:
http://www.linuxjournal.com/article/6953
That link is already included in the post above if you read the fourth paragraph a little bit closer…
Post a comment