dvdauthor [ -o output-dir ] -x xml-config-file
dvdauthor [ -o output-dir ] [ -j | --jumppad ] [ -T | --toc ] [ menu or title --jumppad ] [ -T | --toc ] [ menu or title options ]
At a high level, a DVD is a collection of menus and titles.
At a high level, a DVD is a collection of menus and titles. Conceptually, a menu contains buttons which can be assigned actions and provides a list of choices to the end user, while a title 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. looping) are also available in titles.
The menus and titles are divided into titlesets and the VMGM
The menus and titles are divided into titlesets and the VMGM menu set. A titleset can contain a number of menus and titles which menu set. A titleset can contain a number of menus and titles which are meant to act together. The "menu", "audio", "subtitle", and are meant to act together. The "menu", "audio", "subtitle", and "angle" buttons on the DVD player's remote control will all access menus in the same titleset as the title which is being played. All menus in the same titleset as the title which is being played. All the titles and menus of a given titleset have the same video, the titles and menus of a given titleset have the same video, audio, and subtitle settings (the definitions for the menus are audio, and subtitle settings (the definitions for the menus are independent from the definitions for the titles), so if you want to independent from the definitions for the titles), so if you want to have different settings (for example widescreen vs standard aspect ratios), then you need separate titlesets. Titlesets are not meant ratios), then you need separate titlesets. Titlesets are not meant to jump to one another, so the VMGM menu domain is used. It is a collection of menus (no titles) that can access the menus and collection of menus (no titles) that can access the menus and titles of all the titlesets. titles of all the titlesets.
One of the most frusterating 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 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 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 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. a menu to select among the extras located at the titleset level.
dvdauthor works in discrete operations. It authors each titleset one at a time, and then finally authors the VMGM to titleset one at a time, and then finally authors the VMGM to complete the disc. At that point the contents can be written out to a DVD. If you are controlling dvdauthor with command line arguments, then each step will occur independently; however if you are using the XML configuration file, then you have the option of combining some or all the steps into one.
The VOBs passed to dvdauthor must have DVD NAV (VOBU) packets multiplexed in at the correct locations. Many tools can do this, including mplex from mjpegtools 1.6.0 or later. dvdauthor will then fill these packets in with the correct data. Special care has been taken to ensure dvdauthor is fifo compliant; that is every source VOB can be the output of another program (such as mplex). This can make execution faster on many systems by avoiding extra filesystem accesses.
Here is the basic structure of the configuration file:
<dvdauthor [dest="output-dir"] [jumppad="1|on|yes"] >
<vmgm>
<menus [lang="language-code"] >
<video [format="ntsc|pal"] [aspect="4:3|16:9"]
[resolution="XxY"] [caption="field1|field2"]
[widescreen="nopanscan|noletterbox"] />
<audio [format="mp2|ac3|dts|pcm"] [channels="numchannels"]
[quant="16bps|20bps|24bps|drc"] [dolby="surround"]
[samplerate="48khz|96khz"] [lang="language"] />
[<audio ... />]
<subpicture lang="language" />
<pgc [entry="title"] [palette="yuvfile|rgbfile"]
<pgc [entry="title"] [palette="yuvfile|rgbfile"]
[pause="seconds|inf"]>
<pre> commands; </pre>
<vob file="file.mpg" [chapters="chapter-list"]
[pause="seconds|inf"] />
[<vob ... />]
<button [name="buttonname"]> commands; </button>
[<button ... />]
<post> commands; </post>
</pgc>
[<pgc ... />]
</menus>
</vmgm>
<titleset>
<titleset>
<menus>
[<video ... />]
[<audio ... />]
<pgc [entry="entries"]
[palette="yuvfile|rgbfile"] [pause="seconds|inf"]>
[...]
</pgc>
[<pgc ... />]
</menus>
<titles>
<titles>
[<video ... />]
[<audio ... />]
<pgc [palette="yuvfile|rgbfile"] [pause="seconds|inf"]>
[...]
</pgc>
[<pgc ... />]
</titles>
</titles>
</titleset>
</titleset>
[<titleset ... />]
[<titleset ... />]
</dvdauthor>
A breakdown of the config file:
If the PGC is a menu, you can specify one or more entries for it. This means that if you press the corresponding button on your DVD remote, then it will go to this menu. For a VMGM level menu, the only choice is title, which on my remote corresponds to the top the only choice is title, which on my remote corresponds to the top menu button. For a titleset level menu, you can use root, subtitle, menu button. For a titleset level menu, you can use root, subtitle, audio, angle, and ptt. If you want more than one, separate them by a space or a comma. Note that root entry is meant for commands that jump from a VMGM level menu to a titleset menu. jump from a VMGM level menu to a titleset menu.
All button and menu masks and all subtitles within a PGC must
All button and menu masks and all subtitles within a PGC must share the same 16 color palette. If you use spumux to generate the subtitle/subpicture packets, then the color generate the subtitle/subpicture packets, then the color information will be automatically passed to dvdauthor; however, if you use another subtitler or want to have more control however, if you use another subtitler or want to have more control over the palette, you can manually specify it with the palette attribute. The first 16 entries of the file should be the 16 colors of the palette, listed as 6 digit hexadecimal numbers representing either the RGB breakdown (if the filename ends in .rgb or the YUV breakdown (if the filename does not end in .rgb. After that, the button group information can be listed as pairs of 8 digit hexadecimal numbers; up to three button groups may be specified.
If you have a short video sequence or just want the video to pause at the end, you can use the pause attribute to set the number of seconds (as an integer) from 1 to 254. If you want the video to pause indefinitely, use inf.
The language is quite simple and roughly looks like C.
The DVD virtual machine processes 16 bit values. It supports up to 16 general purpose registers; however dvdauthor reserves 3 for internal use. Thus register 0-12 are avaialable for use and are referred to as g0 through g12.
There are also 24 system registers, which can be referred to as s0 through s23. Not all of these can be set. Many of these have pseodonyms.
Expressions follow typical C syntax except that booleans are not convertible to integers and vice versa. Operators and comparisons are:
==, !=, >=, >, <=, <, &&, ||, !, eq, ne, ge, gt, le, lt, and, or, xor, not, +, -, *, /, %, &, |, ^
Since the code is encapsulated in XML, the parser will catch any unescaped < characters, thus alphabetic mnemonics have been provided for all comparison operators for consistency.
Blocks are either a single statement (terminated by a semicolon), or a group of statements wrapped in curly braces. For example:
g3=s7;
{
audio=1;
subtitle=65;
subtitle=65;
jump vmgm menu 3;
}The statements supported are fairly simple at the moment.
The following are possible targets: