#LyX 1.2 created this file. For more info see http://www.lyx.org/ \lyxformat 220 \textclass book \begin_preamble \usepackage[T1]{fontenc} \usepackage{xspace} \newcommand{\nach}{$\to$\xspace} \newcommand{\hoch}{\texttt{$^\wedge$}} \usepackage{html} \newcommand{\doubledash}{-\hspace{0.1em}-} \newcommand{\doubledashb}{-\/-} \newcommand{\dlt}{{\footnotesize$\ll$}} \newcommand{\dgt}{{\footnotesize$\gg$}} \begin{htmlonly} \renewenvironment{lyxcode} {\begin{list}{}{ \setlength{\rightmargin}{\leftmargin} \raggedright \setlength{\itemsep}{0pt} \setlength{\parsep}{0pt} \ttfamily}% \item[] \begin{ttfamily}} {\end{ttfamily} \end{list} } \newenvironment{LyXParagraphIndent}[1]% {\begin{quote}} {\end{quote}} \renewcommand{\LyX}{LyX} \renewcommand{\doubledash}{\rawhtml --\endrawhtml} \renewcommand{\doubledashb}{\rawhtml --\endrawhtml} \renewcommand{\dlt}{«} \renewcommand{\dgt}{»} \renewcommand{\nach}{\rawhtml to \endrawhtml} \renewcommand{\hoch}{\rawhtml ^\endrawhtml} \end{htmlonly} \end_preamble \language english \inputencoding auto \fontscheme default \graphics default \paperfontsize 11 \spacing single \papersize Default \paperpackage a4 \use_geometry 0 \use_amsmath 0 \use_natbib 0 \use_numerical_citations 0 \paperorientation portrait \secnumdepth 2 \tocdepth 2 \paragraph_separation skip \defskip medskip \quotes_language english \quotes_times 2 \papercolumns 1 \papersides 1 \paperpagestyle default \layout Title VCDMeta Version 0.20 \layout Author Kevin Atkinson \newline kevina@gnu.org \layout Standard \begin_inset LatexCommand \tableofcontents{} \end_inset \layout Chapter Introduction \layout Standard VCDMeta is a Perl script which makes creating easy to navigate VCD extremely simple. It takes in a simplified XML documents which simply contains a list of the Videos you want to include and how you want them to be arranged. From that it will output a XML document suitable for use with vcdimager complete with easy to navigate menus. A text file \begin_inset Quotes eld \end_inset 0VCDINDX.TXT \begin_inset Quotes erd \end_inset is also created which contains the complete contents of the CD for easy navigations when reading the VCD on a computer without VCD menu support. If images are not provided for the menus it will create the menus for you. When the supplied patch is applied to VCDImager, VCDMeta can generating special easy to use mpeg files for use on a computer complete with an HTML index. \layout Chapter Requirements \layout Itemize Perl \layout Itemize XML::Twig Perl module \layout Standard For verifying the input XML file: \layout Itemize xmllint (Part of Libxml, \begin_inset LatexCommand \url{http://xmlsoft.org/} \end_inset , should already be installed as it is also required for the XML front end of vcdimager) \layout Standard For creating and converting images: \layout Itemize Image::Magick Perl module ( \begin_inset LatexCommand \url{http://www.imagemagick.org/} \end_inset ) \layout Standard For converting images into mpeg stills: \layout Itemize netpbm ( \begin_inset LatexCommand \url{http://netpbm.sourceforge.net/} \end_inset ) \layout Itemize mjpegtools ( \begin_inset LatexCommand \url{http://mjpeg.sourceforge.net/} \end_inset ) \layout Standard VCDMeta has not been tested on platforms where Image::Magick is not installed. At very least the line: \layout LyX-Code use Image::Magick; \layout Standard needs to be commented out in VCDMeta. When Image::Magick is not installed the menu images need to be provided as mpeg stills or else the VCDMeta will give errors about not being able to find methods via the Image::Magick package. \layout Standard So far VCDMeta has only been testing on Linux but it should work on any Unix like operating system \series bold . \series default \emph on It should also work on Windows \emph default provided the right Perl modules are installed \emph on with a little effort \emph default . I believe all the required libraries and tools have been ported to Windows, but I have not actually tested VCDMeta on Windows. A windows port of mjpegtools can be found with VCDEasy ( \begin_inset LatexCommand \url{http://www.vcdeasy.org/} \end_inset ). \layout Chapter Installation \layout Standard To install simply unpack the tarbar somewhere such as /usr/local: \layout LyX-Code cd /usr/local/ \newline tar xfvz vcdmeta-X.tar.gz \layout Standard where X is the version of the VCDMeta. If "tar xfvz" doesn't work try "gtar xfvz" or "gunzip -c vcdmeta-X.tar.gz | tar xfv -". This will create a directory \begin_inset Quotes eld \end_inset vcdmeta-X \begin_inset Quotes erd \end_inset . If necessary edit the paths at the top of the VCDMeta script. Then add this directory to your path or create a \emph on symbolic link \emph default to VCDMeta in a directory already in your path. For example: \layout LyX-Code cd /usr/local/bin/ \newline ln -s /usr/local/vcdmeta-X/vcdmeta \layout Standard \emph on Do not just copy \emph default the VCDMeta script. If you do VCDMeta will not be able to find its data files. \layout Standard That should be all thats required. \layout Standard By default some free Type 1 fonts are used for menu creation. For nicer looking menus VCDMeta can use Windows (or any other) True Type fonts. See the top of VCDMeta for what to do to enable them. \layout Chapter Status \layout Standard So Far VCDMeta has only been extensively tested when creating NTSC VCDs. I have verified that VCDMeta runs without errors when creating PAL VCDs but I have not actually tested the VCDs as I have no way of playing them on my DVD player and I have not found any free software that will play VCDs with menu support. Furthermore, even though using mpeg movies for menus \emph on should \emph default work, this has not been tested at all. \layout Standard The latest version of VCDMeta can be found at \begin_inset LatexCommand \url{http://kevin.atkinson.dhs.org/vcdmeta/} \end_inset . \layout Chapter XML Syntax \layout Standard First the header: \layout LyX-Code \newline \layout Standard since the DTD is not stable yet I have chosen not to make it public. Once I am happy with it I will find a place to put it on the web and make it public. \layout Section videocd-meta \layout Standard The root element is videocd-meta. It has the following required parameters \layout Description album-id The album-id same as the album-id for vcdimager \layout Description norm either "ntsc" or "pal" \layout Description class must be "vcd" for now \layout Standard and the following optional parameters: \layout Description title The title for the VCD. No limitation on which characters that can be used \layout Description extra Additional information on the VCD. Displayed below the main title in smaller text when creating menus. \layout Description volume-id The volume-id as given to vcdimager, if it is not given it will be the same as album-id \layout Description publisher-id The publisher-id as given to vcdimager \layout Description nice-mpeg-file-names either \begin_inset Quotes eld \end_inset true \begin_inset Quotes erd \end_inset or \begin_inset Quotes eld \end_inset false \begin_inset Quotes erd \end_inset see section \begin_inset LatexCommand \ref{cha:nice-mpeg-file-names} \end_inset for more info. \layout Description create-mpeg-link-files either \begin_inset Quotes eld \end_inset true \begin_inset Quotes erd \end_inset or \begin_inset Quotes eld \end_inset false \begin_inset Quotes erd \end_inset see section \begin_inset LatexCommand \ref{cha:create-mpeg-link-files} \end_inset for more info. \layout Standard The videocd-element contains the following elements (in the order given) \layout Itemize filesystem \layout Itemize options \layout Itemize page (required) \layout Section filesystem \layout Standard The first optional element inside videocd-meta is "filesystem". This is for adding additional files to the filesystem on the VCD. Its syntax is similar to that used by vcdimager but not the same as I really didn't like how the DTD was done. \layout Standard The filesystem can contain any number of "folder", and "file" elements. \layout Standard A folder takes one required parameter, "name" which is simply the name of the folder. The contents of the folder are the exact same as there are for the filesystem element that is it can contain any number of "folder", and "file" elements. \layout Standard The file element has one required parameter: "src", and two optional ones: "name" and "format". The "src" is the name of the file to include. The "name" is the name of the file as it will appear on the CD. If defaults to the basename of "src" if it is not given. The "format" can either be "form1" or "mixed" and if given is passed on to vcdimager as is. \layout Standard Here is an example of a really stupid filesystem: \layout Standard \newline \newline \newline \newline \newline \newline \newline \newline \newline \newline \newline \layout Section options \layout Standard The next optional element in videocd-meta is "options". It contains several optional parameters: \begin_inset Quotes eld \end_inset auto-split \begin_inset Quotes erd \end_inset , "menu-wait", "menu-loop", "menu-video-wait", all of which control defaults for the "page" elements. The meaning of these parameters will be explained latter. \layout Section page \layout Standard Every VCD must contain at least one page. Multiple pages may be specified. Each page has the following optional parameters: \layout Description title The title used for this page. By default it is the same as the group title. \layout Description extra Supplementary information for this page displayed below the title. By default it is the same as the group. \layout Description auto-split Whether to auto split this page if there are more menu items on this page than can fit on a single screen. Either \begin_inset Quotes eld \end_inset true \begin_inset Quotes erd \end_inset or \begin_inset Quotes eld \end_inset false \begin_inset Quotes erd \end_inset . By default it is set to true unless the \begin_inset Quotes eld \end_inset auto-split \begin_inset Quotes erd \end_inset option for this group is false. If more than one page is specified for any particular group this false is automatically set to false. \layout Description src the source image for the menu. If the extensions is ".m1p" than is assumed to be a mpeg still. If the extension is ".mpg" or ".mpeg" than it is assumed to be an mpeg movie. Otherwise it is assumed to be an image. The image will be converted into an mpeg still for you. The format of the image can be any format ImageMagick can recognize which included jpeg, gif, png, and many others. The image will automatically scaled to the correct size. Finally if this parameter is left out a menu will be created for you. \layout Description wait how long to wait after the image is displayed or video sequence is complete. A value of "-1" means to wait indefinitely until an choice is made. Defaults to "-1" for the root menu. Otherwise defaults to the value of the "menu-wait" parameter specified in the options element if src is a still, or "menu-video-wait" if src is a mpeg video. \layout Description loop how many times to loop an mpeg video. A value of 0 means to loop forever until a choice is made. Defaults to 0 for the root menu or "menu-loop" otherwise. This option should only be specified if src is an mpeg video. \layout Standard The defaults for the parameters of the "options" element are as follows: \layout Standard \begin_inset Tabular \begin_inset Text \layout Standard auto-split \end_inset \begin_inset Text \layout Standard true \end_inset \begin_inset Text \layout Standard menu-wait \end_inset \begin_inset Text \layout Standard 30 \end_inset \begin_inset Text \layout Standard menu-loop \end_inset \begin_inset Text \layout Standard 1 \end_inset \begin_inset Text \layout Standard menu-video-wait \end_inset \begin_inset Text \layout Standard 0 \end_inset \end_inset \layout Standard Each page then contains 1 or more "video" and "group" elements in any order. If the auto-split parameter is set to true any number of elements can be specified. If more menu items are specified than can fit on a page than the page will automatically be split into 2 or more pages. If the auto-split parameter is set to false than a maximum of 9 items can be specified if there is one page. If there is more than one page than a maximum of 8 items can be specified for each page except for the last in which case a maximum of 9 items can be specified. \layout Section video \layout Standard The "video" element is for an actual mpeg video. It contains the following parameters: \layout Description src the mpeg file (required) \layout Description fname the mpeg file name to use if \begin_inset Quotes eld \end_inset nice-mpeg-file-names \begin_inset Quotes erd \end_inset is set. \layout Description title the title of the video as it will appear in the menu \layout Description extra any additional information for the video. This will appear in smaller type below the video's title in the menu if there is room. \layout Subsection entry \layout Standard The video element may contain any number of \begin_inset Quotes eld \end_inset entry \begin_inset Quotes erd \end_inset points. An entry point is simply a way of skipping into the middle of an mpeg movie. Each entry point creates a separate menu item as if it was a separate video. A video can have any number of entry points up until the limits of the VCD standard. The \begin_inset Quotes eld \end_inset entry \begin_inset Quotes erd \end_inset elements contains the following parameters: \layout Description time the position in the mpeg movie. This can either be given in seconds or \begin_inset Quotes eld \end_inset minute:seconds \begin_inset Quotes erd \end_inset format. For example to set the time position to 90 seconds the time parameter can either be \begin_inset Quotes eld \end_inset 90 \begin_inset Quotes erd \end_inset or \begin_inset Quotes eld \end_inset 1:30 \begin_inset Quotes erd \end_inset . (required) \layout Description fname the mpeg link file name to use if \begin_inset Quotes eld \end_inset create-mpeg-link-files \begin_inset Quotes erd \end_inset is set. If not set, then it is derived from the corresponding video \begin_inset Quotes eld \end_inset fname \begin_inset Quotes erd \end_inset . \layout Description title the title of the entry point as it will will appear in the menu. Treated the exact same way as the title parameter for the video element \layout Description extra any additional information for the entry point. Treated the exact same way as the extra parameter for the video element \layout Standard If an entry point at time \begin_inset Quotes eld \end_inset 0 \begin_inset Quotes erd \end_inset is not defined it will automatically be created for you. The title and extra parameter will be the same as the video's title and extra. \layout Section group \layout Standard The "group" element is for creating a sub-menu. It has the following parameters: \layout Description title the title of the group \layout Description menu-title the title of the group as it will appear in the menu choice for this group. Defaults to "title". \layout Description extra any additional information for the video. This will appear in smaller type below the group's title. \layout Description menu-extra any additional information as it will appear in the menu choice. Defaults to "extra". \layout Standard \begin_inset LatexCommand \label{groupsc} \end_inset Instead of writing this: \layout Quote \series bold menu-title \series default = "60 Minutes, July 2002" \newline \series bold menu-extra \series default = "Dancing With Wolves" \newline \series bold title \series default = "60 Minutes" \newline \series bold extra \series default = "July 2002" \layout Standard You can instead: \layout Quote \series bold title \series default = "60 Minutes \series bold ,, \series default July 2002" \newline \series bold menu-extra \series default = "Dancing With Wolves" \layout Standard Notice the double comma in the title. A similar thing can be done with a double colon (::), or double semi-colon (;;) \layout Standard The contents of the "group" elements is almost the same as the videocd-meta element except that the filesystem element is not allowed. More specifically the group may contain the following elements which behave the same way as the do in videocd-meta unless otherwise specified. \layout Description options any options specified control the defaults for this group and any of its sub-groups \layout Description page (required) \layout Section Examples \layout Standard And thats all there is to it. Here are some illustrative examples. A basic single level menu VCD: \layout LyX-Code \newline \newline \newline \newline \newline \layout Standard A more complex VCD: \layout LyX-Code \newline \newline \newline \newline \newline \newline \newline \newline \newline \newline \newline \newline \newline \newline \newline \layout Standard This VCD uses the options element to set the default wait time to 15 seconds instead of the usual 30. It has two sub menus and 4 videos with video 1 having two entry points. The root menu uses a mpeg movie instead of the default menu created by VCDMeta while Menu 1 uses an png file. Menu Two uses the short cut discussed in \begin_inset LatexCommand \ref{groupsc} \end_inset . \layout Chapter Layout of the Videocd \layout Standard VCDMeta will lay out the videocd in a manner which makes navigating the cd easy and convenient. The following example will be used though out this section to make the explanation easier. \layout Itemize Root \begin_deeper \layout Itemize Root Page \begin_deeper \layout Itemize Group 1 \begin_deeper \layout Itemize Page 1.1 \begin_deeper \layout Enumerate Video 1.1 \layout Enumerate Video 1.2 \end_deeper \layout Itemize Page 1.2 \begin_deeper \layout Enumerate Video 1.3 \layout Enumerate Video 1.4 \end_deeper \end_deeper \layout Itemize Video 2 \layout Itemize Group 3 \begin_deeper \layout Itemize Page 3.1 \begin_deeper \layout Enumerate Video 3.1 \layout Enumerate Video 3.2 \end_deeper \end_deeper \end_deeper \end_deeper \layout Standard The rules are as follows: \layout Enumerate The numbers 1-9 will select a menu choice, in addition these numbers may be used to jump from one video to the next when playing a video. For example selecting \begin_inset Quotes eld \end_inset 2 \begin_inset Quotes erd \end_inset when playing video 1.1 will jump to video 1.2. Selecting \begin_inset Quotes eld \end_inset 2 \begin_inset Quotes erd \end_inset when playing video 1.2 will jump to video 1.1. That is when playing a video selecting a number will jump to the menu choice in the most recent menu. For video's 1.1 and 1.2 this will be menu 1 and for video's 3.1 and 3.2 this will be menu 3. \layout Enumerate Selecting \begin_inset Quotes eld \end_inset next \begin_inset Quotes erd \end_inset from a page will go to the next page in that group if there is one, otherwise it will go to the first selection in that \emph on group \emph default . For example selecting next from page 1.2 will go to video 1.1, \emph on not \emph default video 1.3 which is the first selection for that page. selecting next from a video will go to the next menu item in that group, if there is one, otherwise it will go to the next menu item in the previous group. For example selecting next in video 1.4 will go to video 2. \layout Enumerate Selecting \begin_inset Quotes eld \end_inset prev \begin_inset Quotes erd \end_inset will in do the reverse of \begin_inset Quotes eld \end_inset next \begin_inset Quotes erd \end_inset unless at the root menu in which case \begin_inset Quotes eld \end_inset prev \begin_inset Quotes erd \end_inset will do nothing. \layout Enumerate The \begin_inset Quotes eld \end_inset return \begin_inset Quotes erd \end_inset key will generally go one level up. For example hitting the return key while video 3.2 in playing will go to page 3.1. Selecting return when at page 3.1 will go to the root page. If there are multiple pages for a group than than it will go to the previous page. For example hitting the return key while at page 1.2 will go to page 1.1. Selecting return when at the root page will do nothing. \layout Enumerate When a menu times out or a video is finished playing the next item will be played as if \begin_inset Quotes eld \end_inset next \begin_inset Quotes erd \end_inset was selected. \layout Enumerate The \begin_inset Quotes eld \end_inset default \begin_inset Quotes erd \end_inset key (often the play button) serves the same function as the \begin_inset Quotes eld \end_inset next \begin_inset Quotes erd \end_inset key. \layout Chapter nice-mpeg-file-names \begin_inset LatexCommand \label{cha:nice-mpeg-file-names} \end_inset \layout Standard In order to use this option VCDImager must be patched to support creating the special mpeg files. When this option is set to true then special mpeg files will be created on the CD, in the MPEG/ directory, which can be played directly on Windows and the Mac (I believe). Unfortunately these special files will not work on Linux. These files are like the *.DAT files found in the MPEGAV/ sequence but end in \begin_inset Quotes eld \end_inset .MPG \begin_inset Quotes erd \end_inset instead of \begin_inset Quotes eld \end_inset .DAT \begin_inset Quotes erd \end_inset so that they can be played directory without having to associate the .DAT files to a media player. \layout Standard An HTML index file is also created in the MPEG/ directory when this option is set. \layout Chapter create-mpeg-link-files \begin_inset LatexCommand \label{cha:create-mpeg-link-files} \end_inset \layout Standard When set to true mpeg link files will be created on the CD in the MPEGLINK/ directory. These files end in \begin_inset Quotes eld \end_inset .MPL \begin_inset Quotes erd \end_inset and contain exactly 2 lines. The first line is the MPEG track number, and the second line is the offset in seconds. Unlike the special MPEG files above these files can be used to play the video cd on Linux provided the the .MPL links are set up to a player capable of playing VCD on Linux. The link files, unlike the special MPEG files, also allow entry points to be played. Like the special mpeg files, an HTML index is created in the MPEGLINK/ directory when this option is set. \layout Chapter Running VCDMeta \layout Standard Running VCDMeta is extremely simple. Since VCDMeta will create a large number of files it is best to create a separate directory for each videocd you wish to create and copy the input XML file into it. Once a directory has been created simply change into the directory and type \begin_inset Quotes eld \end_inset vcdmeta [xmlfile] \begin_inset Quotes erd \end_inset . The xmlfile can be left off if your input file is named \begin_inset Quotes eld \end_inset videocd-meta.xml \begin_inset Quotes erd \end_inset . That's all there is to it. VCDMeta will then create the vcdimager input xml file as \begin_inset Quotes eld \end_inset videocd.xml \begin_inset Quotes erd \end_inset in the current directory, an index file \begin_inset Quotes eld \end_inset 0VCDINDX.TXT \begin_inset Quotes erd \end_inset , and various other files needed for the displaying of the menus on the videocd. \layout Chapter Changelog \layout Subsection* Changes from 0.10 to 0.20 (Dec 27, 2002) \layout Itemize Changed DTD. The new DTD in not compatible with the old one form VCDMeta 0.10. \layout Itemize Added support for multiple pages in a group. \layout Itemize Added support for nice mpeg file names and mpeg links. \layout Chapter Copyright \layout Standard Copyright (C) 2002 by Kevin Atkinson under the GNU General Public License (GPL) version 2.0. You should have received a copy of the GPL along with this program if you did not you can find it at the GNU web site \begin_inset LatexCommand \url{http://www.gnu.org/} \end_inset or more specifically \begin_inset LatexCommand \url{http://www.gnu.org/licenses/gpl.html} \end_inset . \layout Standard The included fonts, \begin_inset Quotes eld \end_inset Helvetica-bold-r-*.pfb \begin_inset Quotes erd \end_inset , are Copyright by URW++ Design and Development GmbH, and are also under the GPL. \the_end