|Microsoft DirectX 9.0|
The features that make DVD attractive to consumersseamless branching, multiple languages, parental control, karaoke support, and multiple anglesalso make the developer's job a little more complex. A DVD player must not only play back audio, video, and subpicture streams, but also must keep track of the navigation options that the disc is currently permitting, and correctly handle many types of user commands. The DVD Navigator shields you from much of this complexity while enabling you to create a fully-functional DVD application. You do not need to refer to the DVD specification to use the DVD Navigator API effectively, but you do need to know basic DVD navigation concepts. The following sections provide some necessary background information. You can find further information on DVD in third-party publications or on the World Wide Web.
The audio and video data on a DVD-Video disc is interleaved at regular intervals with various kinds of navigation control data. This data may be an instruction that tells the player to do something, for example move to some particular place on the disc, or it may be an informational-only marker informing the player for example that the content that follows has a higher parental management level than the previous content, or that the chapter skip operation is disabled. The player relays this information to an application, and it is the responsibility of the application to act on it. These navigation markers are part of what give DVD its higher level of user-interactivity compared to Video CDs. A DVD-player application must handle events that originate with the disc as well as events that originate with the user.
A DVD-Video disc contains three primary types of streams: video, audio and subpicture.
The main logical division on a DVD-Video disc is a title. A title can represent an entire movie or a 30-second video clip. There may be up to 99 titles on a disc and disc authors may divide the title into as many as 999 logical chapters. In most feature films on DVD, movie content is formatted as a series of chapters which automatically play one after another. On such discs, the end-of-chapter marker contains a branching instruction that tells the player to continue playing the next chapter in the sequence. These titles are referred to as One Sequential PGC Titles. (PGC stands for program chain, another name for a group of chapters that belong together. This term is not used in the DVD Navigator documentation.) On discs with other types of content, such as karaoke discs, an end-of-chapter marker might instruct the player to show a menu, or it might simply instruct the player to stop.
DVD application developers use title and chapter numbers to jump to specific points on a disc. For finer access, a title number and timecode can be used. Timecodes can only be used with One Sequential PGC Titles, since other types do not contain timecode maps.
Menus are the principle means by which users interact with the content on a DVD when played in a traditional player. Menus enable users to choose which video title to show, which audio soundtrack to play, which subtitles to display, which camera angle to view, and what other special features to enable. DirectShow DVD application developers have the choice of enabling menus as in a traditional player or creating a new computer-based interface that replaces or supplements the menus authored on the disc. The application can also simulate user interaction by programmatically selecting and activating menu buttons.
The Video Manager Menu
The top level menu is the Video Manager Menu (VMGM), also called the Top Menu or Title Menu. This menu usually has buttons that enable the user to go to the main titles or groups of titles on the disc. A group of titles is called a title set. For example, on a disc that has a feature film, a title set called "Interviews With the Director and Cast," and a title set called "Coming Attractions," the VMGM would probably have three buttons. Clicking the "Coming Attractions" button would take the user to a Video Title Set Menu (VTSM) with buttons for each separate title in the title set.
Because a disc can contain soundtracks in up to eight languages. It can also contain multiple VMGMs in languages that correspond to those on the soundtracks.
The VMGM appears when the user starts playing the disc unless the first title on the disc is authored as an autoplay title. In this case there may not be a VMGM. Most feature films on DVD are authored as autoplay titles.
Video Title Set Menus and Submenus
A Video Title Set Menu, also called a Root Menu (even though it's not at the root!), is a submenu of the VMGM. There can be from 1 to 99 titles in a title set. The VTSM has buttons enabling the user to go to any of the titles in the title set. In addition, the VTSM can also have submenus which enable the user to go to choose options for the audio stream, camera angle, subpicture stream, or chapter. These submenus are always valid for all the titles in the title set. VTSM submenus are not used on most DVDs. The root menu and all other submenus are optional, so never assume that all submenus in a VTSM have a common root menu.
All or part of a DVD disc can be encoded with a Parental Management Level (PML) numbered from one to eight. Eight is the most restrictive level (adults only) and one is the least restrictive (all ages). The idea is to prevent children from watching adult content without parental consent, while allowing adults to watch child-safe content. In the United States and Canada, the levels map to the rating system of the MPAA (G, PG, PG-13, NC-17), but this is not the case in other countries or regions.
Because chapters can exist logically within a parental block, there may be two versions of the same chapter in a title, each assigned a different PML and in a different parental block. For example, a child who logs in and plays the disc would see one version of Chapter 3, and an adult who logs in would see a different version, assuming that the application supports PMLs.
A title or chapter can also contain temporary PMLs, whose content is rated higher than the PML for the title or chapter as a whole. This means that a title may have more than one parental level. Temporary PMLs are generally authored as angle blocks, so that a scene in a film may have two versions, one rated for younger viewers and one for adults.
It is the responsibility of the player application to enforce the parental levels.
The concept of the domain is very important to DVD navigation, but domains are not physically marked on the disc in the same way that titles, menus, and angle blocks are, and so DVD authors have no control over them. A DVD domain can be thought of as a type of state variable, with five possible values, that a DVD player monitors in order to keep track of the type of content that the player is currently reading from the disc. DVD players use domains to keep from issuing meaningless commands to the DVD drive. For example, a "SelectButton" command is only meaningful if a menu is displayed, and a "FastForward" command makes no sense if the player is currently stopped or is showing a menu, which is a still image. The following table summarizes the domains and their meaning from the perspective of an application.
|Domain||What the DVD Navigator is reading|
|First Play||The initial section of the disc, for example, the FBI warning.|
|Video Manager Menu||The main menu for the entire disc or disc side. Any menu-related methods are valid.|
|Video Title Set Menu||The menu for a title or group of titles, or one of its submenussubpicture, language, audio, or angle. Any menu-related methods are valid.|
|Title||The video content in a title. The menu-related methods are not valid.|
|Stop||Nothing. The head is retracted from the disc. From here you can call Play.|
User Operation Controls (UOPs) are markers on a disc that DVD authors can insert anywhere to restrict a user's navigation options. Most discs follow standard UOP restrictions. For example, most discs do not allow the viewer to fast forward or show a menu while in First Play domain. In principle, each disc can insert any UOP command at any point on the disc, even if the command would otherwise be valid within the current domain. For example, a disc may be authored to disallow fast forwarding in a certain title or to prevent a particular menu from being shown after the user enters the title domain. The DVD Navigator complies with all such commands from the disc and will not allow an application to override the disc's UOP controls.