Storing Bitmap Files Within a Title

Generally, Viewer stores bitmaps along with audio, animation, and other multi-media elements in a title, using the MS-DOS file system. However, Viewer titles have their own file system, and you can store bitmaps in this file system to give Viewer more efficient access to them. This is because Viewer doesn't have to read the path table from the CD-ROM when it needs access to files.

To store bitmaps within the title's own file system, specify them in the [BAGGAGE] section of the project file. You can store as many as 1,000 baggage files. Simply list the files you want to store under the [BAGGAGE] heading. In this list, use paths relative to the ROOT option if the project file has a ROOT option; otherwise, use paths relative to the project directory. For example, to store the file AZ_NICK.DIB in the title's file system, and that file is in the DIBS subdirectory of the project directory, the [BAGGAGE] section appears as follows:

[BAGGAGE]
bag.ini
dibs\az_nick.dib

The [BAGGAGE] section in this example includes the required reference to the BAG.INI file. (See Chapter 5, “Building the Title,” and Chapter 11, “Advanced Build Options,” for more information about this file.)

In topic files, when you enter a reference to a baggage file, you must enter the filename preceded by an exclamation point (!). Enter the filename exactly as you entered it in the [BAGGAGE] section, but with no path. For example, to display the file AZ_NICK.DIB (in the DIBS subdirectory) in an extended window, with that file specified in the [BAGGAGE] section of the project file, you would enter the following command in the topic file to display the extended window:

Grand Canyon!HDisplayBmp(hwndContext, qchPath, "!az_nick.dib","Grand Canyon")