#include "ILTDvdWriter2.h"
C Syntax |
HRESULT ILTDvdWriter_AddMenuTitle(pDVDWriter, Title The name for a group of related video files (called "Chapters") on your DVD. For example, for a DVD called "My Summer Vacation," you might have the titles "Water Skiing," "New Friends," and "Hiking." For each of those titles, you might have one or more different video files., Index) |
C++ Syntax |
HRESULT AddMenuTitle(Title, Index) |
ILTDvdWriter *pDVDWriter; |
/* pointer to an interface */ |
BSTR Title; |
/* title text */ |
long Index; |
/* title index */ |
Adds a new title to the menu.
Parameter |
Description |
pDVDWriter |
Pointer to an ILTDvdWriter interface. |
Title |
A character string that contains the title text that will appear in the menu. |
Index |
A zero-based index of the title; where the title will be inserted in the list of titles. Pass -1 to append the title to the end of the list. |
Returns
S_OK |
The function was successful. |
<> S_OK |
An error occurred. Refer to the Error Codes or the HRESULT error codes in the DirectShow documentation. |
Comments
The title list can be modified at any time before writing the menu. A maximum of 36 titles can be added. Calling ILTDvdWriter::AddMenuTitle with an existing index will not make an update: it will insert a new title at the specified index and shift the list down.
Menu writing should be the last step in a DVD image A set of files that contain all of the video and audio content for a DVD, organized with a table of contents (optional). See also: Title, Chapter The name for each individual video file on a DVD. For example, under the title "Water Skiing", you might have the chapters "My first try," "My first wreck," and "My first jump.", ISO Image An ISO image (.iso) is a disk image of a file system. It includes data files that are contained in the ISO image along with filesystem metadata. ISO images are an alternative to physical media for distribution of a "DVD" over the Internet. Most operating systems allow ISO images images to be "played" as if they were physical discs. See also: DVD Image.. authoring process. Writing the menu first will cause an error and if a new title is written after the menu has been written, then the menu will be destroyed.
Any multimedia file can be used as the menu background, including a single page image, a multipage image, or a video. All menus require a background video. To add menus to the DVD image, perform the following steps:
1. |
Add menu titles by calling the ILTDvdWriter::AddMenuTitle function. |
2. |
Call the ILTDvdWriter::put_TitleMenu, passing VARIANT_TRUE to the newVal parameter. |
3. |
Convert the background image for the menu. This is a standard DVD conversion graph, only the video will be used for the menu background. |
4. |
Call ILTDvdWriter::put_TitleMenu, passing VARIANT_FALSE for the newVal parameter to close the "menu write" mode. This merges the menu subtitle information with the background video and modifies the DVD image. |
Required DLLs and Libraries
LTDVDWRT For a listing of the exact DLLs and Libraries needed, based on the toolkit version, refer to Files To Be Included With Your Application. |
See Also
Functions: |
ILTDvdWriter::RemoveMenuTitle, ILTDvdWriter::RemoveAllMenuTitles, ILTDvdWriter::get_MenuTitleCount, ILTDvdWriter::GetMenuTitle |
Topics: |
|
|
|
|
|
|
|
|
Example
For a C example, refer to Creating DVD Images for C.
For a C++ example, refer to Creating DVD Images for C++.