by William Robert Stanek
Multimedia is the driving force behind the phenomenal popularity of the World Wide Web. By adding sound and video, you can create visually stunning, highly interactive, dynamic pages that entice readers to visit your page time after time. This chapter
is filled with insider tips and techniques for incorporating multimedia into your publications.
Direct support of multimedia, plug-ins, Java, and VRML is making live multimedia publications on the Web a reality. Behind this first wave of inline multimedia capabilities is a second wave carrying even more advanced capabilities. This new wave of
technology is bringing with it the capability to create live documents that either execute or update in real time.
Using inline multimedia, you can create documents with full-motion video and soundtracks. Innovations such as RealAudio enable you to create soundtracks that begin playing almost as soon as they are accessed. Plug-ins, such as the Macromedia Director
plug-in available for the Netscape Navigator, enable browsers to incorporate features from advanced multimedia tools.
The Java programming language is poised to storm the application's development marketplace like no other programming language before it. In the coming months, you will find that if a browser developer wants to be taken seriously in the race to develop
the ultimate browser, his or her browser must support Java. Web users will demand this because their favorite destination sites will increasingly employ Java applets. (Part IX, "JavaScript and Java," includes more information on the Java
programming language.)
The hottest innovation for VRML is the live application engine. Using a live application engine, you can transform static 3-D worlds into worlds filled with live animation. Although point-and-click in a 3-D environment is fun, nothing compares to
entering a 3-D world with spinning, moving, and flying objects that race by and, based on your actions, intelligently interact. If you want to create live VRML documents, learn all you can about Microsoft's ActiveVRML and the Moving Worlds VRML 2.0
specification.
ActiveVRML is based on in the VRML 1.0 specification. Both ActiveVRML and Moving Worlds are specifically designed to meet the needs of Web publishers who want to create multimedia interactive animation.
With VRML 2.0, you can leave behind the static and lifeless VRML 1.0 worlds and enter worlds rich in interaction and animation. VRML 2.0 includes many realism enhancements for objects and backgrounds. For example, publishers can automatically generate
irregular terrain. There are additions for generating spatial 3-D sound, which allows publishers to create sounds that grow louder as you approach and fade as you move away.
Some of the best enhancements for VRML 2.0 are the ones that help publishers create animation. The best VRML animation is triggered by user events, but best of all, every movement in a Moving World can trigger new events. When you walk up to a virtual
house and ring the bell, an eerie voice can tell you to come in, and the front door can slowly open. To allow for timed events, you can include counters that track the time. For example, a grandfather clock can echo out the time precisely on the hour and
half hour.
VRML 2.0 also lets you detect object collisions, which gives substance to every virtual object. Now that you can detect when objects collide, you can ensure that the virtual tourists to your world can't walk through wallsunless you want them to.
If all this sounds complicated, consider the following example. A visitor to your VRML world is racing toward a black hole you've created in the center of your cybergalaxy. Your VRML world file feeds data to the appropriate program modules according to
the speed and direction they are traveling. Using this input, you can vary the sounds the visitor hears as he or she speeds up or slows down. You can decrease the intensity of celestial bodies as the visitor begins to enter the black hole's gravitational
field and so on.
Using these same live functions, you could create a live cybermall populated by the visitors to the mall. Here, your real-time world would change as visitors move around the mall. Doors could open and close. Visitors could chat with each other. They
could interact with information desk personnel to find the products they are looking for.
If the VRML cybermall just described seems far off, consider browsers such as the Sesame Navigator from Ubique that let you invite friends to cybersurf with you. Although Sesame Navigator uses HTML to create what it calls virtual places, it is only a
matter of time before someone integrates this capability into VRML.
NOTE
You can learn more about these innovations at the following Web sites:
- RealAudio: http://www.realaudio.com/
- ActiveVRML: http://www.microsoft.com/
- The Moving Worlds VRML 2.0: http://webspace.sgi.com/moving-worlds/
- VRML resource: http://www.sdsc.edu/vrml/
- Sesame Navigator: http://www.vplaces.com/index.htm
Many Web publishers are experimenting with sound in their publications. These publishers have found that Web users everywhere find sound fascinating and often visit sites solely to obtain sound clips. You can include many types of sound in your
publications. Here are some ideas:
Technologies revolving around sound are growing at an explosive pace on the Web. You might be surprised to find that you can include internal and external sound clips in your publications. A few months ago, it would have been impossible to add a
soundtrack to a publication. Now, not only can you include a soundtrack for your publications, but you can include multiple soundtracks for publications that play on cue when the part of the page containing the sound clip appears in the browser's viewing
area. The potential uses of internal sound files are phenomenal and will take Web publishing to a new high. (See the section "Creating Documents with Soundtracks" later in this chapter for more information.)
Although support for internal sound files is just beginning, support for external sound files is already widespread. Readers can access external sound files by activating a hypertext link to the sound file. You can easily create a link to a sound file
in the FrontPage Editor.
In the editor, select the text or image that identifies the link and then either choose Hyperlink from the Edit menu or click the Create or Edit Hyperlink button. This opens the Create Hyperlink dialog box. In the Create Hyperlink dialog box, click
either the Current Web tab or the World Wide Web tab.
To create a link from the Current Web tab, enter the relative or page URL for the sound file in the Page field, such as rainstorm.wav. If you do not know the URL, click the Browse button to display the Current Web dialog
box. Using this dialog box, select the page or file you want to link to and then click the OK button.
To create a link from the World Wide Web tab, select the HTTP protocol from the list of supported protocols. The Editor creates the protocol portion of the URL in the URL field. In the URL field, enter the absolute URL of the sound file to which you
want to link. When you are finished, click the OK button. In the example shown in Figure 11.1, the link points to a WAV audio file at http://tvp.com/idn/intro.wav.
Figure 11.1. Adding a reference to an external sound file.
When a reader clicks the link, the browser downloads the sound file to his or her computer. If a sound player is available and configured for use in the reader's browser, the sound file plays. If a sound player is not available, the browser stores the
sound file on the reader's hard disk for later playing.
Many browser packages come with a sound player, especially commercial browser packages. The Netscape Navigator package includes a sound player called NAPLAYER. NAPLAYER can play most popular sound formats including AU, SND, AIFF, and AIFF-C.
Browsers know which sound player to launch based on the file type extension (.au, .aiff, .wav, and so forth) of the external sound file referenced in your document.
When a reader accesses a link to a WAV file, the browser checks a configuration table to see which application should play the sound file. For this reason, you should always name your Web files with the appropriate extension. If the file is in WAV format,
name it with a .wav extension. If the file is in AIFF format, name it with an .aiff extension.
Deciding when and how to use sound is one of the most important choices you as the Web publisher have to make. You can use sound in your publications in many ways, but it's especially useful for enhancing and supplementing the text and images on the
page. Although adding sound to your documents is easy (using links to external sound files), there are many concepts to consider before adding sound.
Most computer systems come equipped with all the necessary equipment to create sound files:
If your computer does not have this equipment, you can purchase a sound kit, such as the SoundBlaster Pro 16 kit from Creative Labs.
The first step in making a recording is generally to plug a microphone into the sound input jack on your sound card. Using a microphone to make recordings is an analog-to-digital process that most computers can handle. If you want to record a digital
audio source, such as music from a compact disc or digital audio tape, you can record directly into the audio jack of the sound card. When you do this, the digital source is usually automatically converted to analog and then back to digital.
NOTE
It might seem strange to convert a digital signal to an analog signal so you can record it in digital format. However, the conversion is necessary because most computers and sound cards do not support digital inputs. If you want to make a true digital-to-digital recording, you need to obtain specialized equipment. Fortunately, however, most of the time you do not need specialized equipment. Most CD and DAT players have an internal analog-to-digital converter that outputs analog sound on a standard output jack. Using an extension cord that connects the output jack of the CD or DAT player to the input jack of the computer, you can make recordings. Keep in mind, however, that the conversion process from digital to analog back to digital could degrade the audio signal.
You can use digitized voice to personalize your Web publications. You can provide a prerecorded greeting from your CEO or marketing specialist or from the author of the latest work you are featuring. Not only can digitized voice add a personal touch to
your publication, but it also has many practical uses. You can use a sound file to provide commentary on the document's subject matter, which can give readers wonderful insight into the author's thoughts. Before you can add the digitized voice file to your
page, you must create the sound file. You can create digitized voice files using a microphone and the audio tool that came with your computer.
You can also use your microphone and audio tool to create or record sound effects. Useful sound effects include doors slamming, horns honking, and jet engines roaring. If you want to add the splashing sounds of a spring rainstorm to your publication,
you can record the sounds using a standard tape recorder and then later digitize the sounds. To do this, you could connect the output of your tape recorder to the input of your computer's sound card. Alternatively, you could simply press Play on the
recorder and use your computer's microphone and audio tool to record the sounds from the recorder's speaker. You could also hold your computer's microphone near an open window to record your street noises or rainstorm sounds directly.
The key to linking sound files to your documents is to do it in an unobtrusive way. Although you do not want to say "Click here to access a sound file," you want to let the reader know the format and size of the sound file. One way to do this
would be to simply insert the information within the link or after the link, like so:
sound of thunder (760KB WAV)
Greetings from our CEO! (150KB AU)
Consider very carefully the sampling rate for your recordings. You might be surprised to learn that sound files gobble up 150KB to 10MB of hard disk space per minute. A voice-quality recording sampled at 8kHz uses approximately 150KB per minute.
Voice-quality recordings, also referred to as 8-bit mono recordings, are useful for all general-purpose recordings, including recordings of digitized voice, sound effects, and simple tones. A high-fidelity recording sampled at 44.1kHz uses approximately
10MB per minute. High-fidelity recordings, also referred to as 16-bit stereo recordings, are useful whenever you want to make stereo recordings to include recordings of music from compact disk or digital audio tape.
The primary difference between a mono recording and a stereo recording is the number of audio channels used. Mono recordings use only one audio channel. Stereo recordings use two audio channels. When mono recordings play on a system equipped for stereo
playback, the same channel plays in both the left and right speakers. When stereo recordings play on a system equipped for stereo playback, one channel goes to the left speaker and the other channel goes to the right speaker. Although a growing number of
computers can play stereo sound files, the average computer does not have stereo speakers. The average computer can play only 8-bit mono sound.
Although 8kHz and 44.1kHz are the most commonly used sampling rates, some Web publishers use other rates as well. One rate you might see is 22.05kHz, which is one half the 44.1kHz sampling rate. Many Web publishers use this rate to record one channel
or the mono equivalent of a stereo recording. This is useful because it cuts in half the size of the resulting file. Instead of using 10MB per minute, the 22.05kHz sound file uses 5MB per minute.
Another sampling rate you might see is 22kHz for stereo sound files and 11kHz for mono sound files. Because the sound is sampled at a lower rate, the resulting files use less disk space. You might see this sample rate used on Macintosh computers with
System 7 and on Windows systems.
Don't forget, you can create sound clips using an audio tool. Most computer systems come with an audio tool capable of recording sound from the computer's standard input. Using an audio converter, you can convert to and from the popular sound formats
discussed in the next section.
When adding sound files to your publication, you should keep the length of the recording to a minimum. The smaller the file, the more quickly the reader can download and play back the file. You have already seen one way to reduce the size of the file
(by reducing the sampling rate). Another way to reduce the file size is to use an audio format that compresses the sound file. One such format is MPEG, developed by the Moving Pictures Expert Group.
MPEG is the world standard in audio and video compression. Just as JPEG images and other graphic images can be compressed, so can digital audio and video. MPEG is a technical standard for compression, not a compression algorithm. Manufacturers who
follow the MPEG standard develop or obtain a proprietary compression algorithm to achieve what the standard defines. A compression algorithm is a program that uses an advanced mathematical formula to squeeze audio and video into smaller disk spaces. Using
MPEG, you can compress a 10MB sound file into 1MB or even 1/2MB of disk space.
When you compress files, there is a trade-off between compression and the quality of the playback. The higher the compression ratio, the more information squeezed out of the recording and the lower the quality of the playback. For MPEG audio, you might
want to use a compression ratio of 7:1 to 12:1. MPEG audio players are available for most computer systems, including Amiga, DOS/Windows, Mac, and UNIX. You can use MPEG audio to produce high-quality stereo sound sampled at 44.1KHz; because the files are
compressed, the resulting files are small compared to other stereo formats.
The sound format you should use depends on your publishing needs and the projected needs of your readers. Each computer platform has its own sound format. In fact, most computer platforms have several formats, which makes it difficult to adapt sound
for use on different systems. This is why industry standards such as MPEG are so important.
Although MPEG audio is used widely, other formats are even more prevalent on the Web. Some of these formats are so popular they seem to be industry standards. Sun Microsystem's audio format AU is one of these formats.
Sun's audio format is also called the mu-law format. AU formatted sound files use the .au extension. The AU format originated on Sun workstations in the UNIX environment. Although the AU format is not a high-quality format,
it enjoys wide usage because many platforms support it. Audio players are available for just about every computer platform, including Amiga, Atari, DOS/Windows, Mac, and UNIX. AU sound files with a sample rate of 8kHz are the most common and offer fair
sound quality that is a close equivalent to that of a telephone receiver.
Two audio formats are associated with Apple's Audio Interchange File Format. AIFF is a basic format that supports high-quality stereo sound. AIFF-C is an advanced format that enables you to compress audio files up to a ratio of 6:1. Using these
formats, you can create sound files sampled at a variety of rates. The most popular sampling rates are 16-bit stereo at 44.1kHz and 8-bit mono at 8kHz.
On most systems, AIFF files use the .aiff extension and AIFF-C files use the .aifc extension. Because DOS/Windows systems limit extensions to three letters, both AIFF and AIFF-C files use the
.aif extension on DOS/Windows computers. Because Apple originally developed these formats, the formats are primarily used on Macintosh systems. Most audio players that support AIFF also support AIFF-C and audio players are
available for just about every computer platform, including Amiga, DOS/Windows, Mac, and UNIX.
Microsoft's Waveform audio format is another popular format. WAV-formatted sound files use the .wav extension. The proprietary WAV format originated on Windows systems and is capable of producing high-quality sound. Using
WAV, you can create sound files sampled at a variety of rates. The most popular sampling rates are 16-bit stereo at 44.1kHz and 8-bit mono at 8kHz. Audio players are available for just about every computer platform, including Amiga, DOS/Windows, Mac, and
UNIX.
The SND format is a basic format used in various ways on different systems. On some UNIX systems, audio files saved with the .snd extension are actually AU sound files. DOS/Windows systems use a basic sound format saved
with the .snd extension as well. Macintosh systems also use a basic sound format that is saved with the .snd extension. On System 7 for Macintosh, popular sampling rates for SND formatted sound
files are 22kHz for stereo sound and 11kHz for mono sound.
Other popular formats include the Musical Instrument Digital Interface (MIDI) format and digital music files in module (MOD) format. MIDI sound files are not sampled like other sound files; they contain instructions for how and when to play electronic
synthesizers. Using MIDI, you can create very advanced soundtracks that use a very small amount of disk space. To play back MIDI sound files, you need a MIDI player.
Modules (MODs) refer to a group of sound formats. MOD files are not sampled; they contain sets of digital music samples and sequencing information for those samples. There are more than 100 MOD formats. The three most popular of these formats are MOD,
S3M, and MTM. Although MODs originated on the Amiga, any computer system when using a compatible audio player can play popular MOD formats.
Table 11.1 shows the popular audio formats and summary information for each format. As you have seen, audio players are available for a variety of sound formats on most computer platforms. However, if you want to ensure that a particular group of users
can play your sound file, you should use a sound format that originated on their system.
Format | Extension | MIME Type | Common Sample Rates | Compression |
AIFF | .aif/.aiff | audio/x-aiff | 44.1kHz, 16-bit stereo | None |
8kHz, 8-bit mono | None | |||
AIFF-C | .aif/.aifc | audio/x-aiff | 44.1kHz, 16-bit stereo | 6:1 |
8kHz, 8-bit mono | 6:1 | |||
AU/mu-law | .au | audio/basic | 8kHz, 8-bit mono | None |
MPEG | .mp2 | audio/mpeg | 44.1kHz, 16-bit stereo | 20:1 |
SND | .snd | audio/basic | 22kHz, stereo | None |
11kHz, mono | None | |||
WAV | .wav | audio/x-wav | 44.1kHz, 16-bit stereo | None |
8kHz, 8-bit mono | None |
One of the best places on the Web to find sound resources is Yahoo. At Yahoo, you can find links to hundreds of resources related to sound. The following links take you to some of Yahoo's most popular sound pages:
Yahoo's multimedia sound page
Yahoo's MIDI sound page
Yahoo's MOD music page
Another great place to find resources related to sound is the World Wide Web Virtual Library. The WWW Virtual Library maintains an audio index and a music department.
Audio index at the WWW Virtual Library
Music Department of the World Wide Web Virtual Library
If you are looking for sound archives, this popular archive contains a lot of Sun AU sounds and a large collection of Ren and Stimpy sounds:
Another good sound archive is Sunsite. Although Sunsite maintains a multimedia archive, the best stuff is in these sound directories:
AU sounds
WAV sounds
Music
To stay current with audio concepts and resources, you might want to participate or lurk in the newsgroups related to sound. Here are some newsgroups you might be interested in:
alt.binaries.sounds.misc alt.binaries.sounds.midi alt.binaries.sounds.mods alt.binaries.sounds.movies alt.binaries.sounds.music alt.binaries.sounds.tv
alt.binaries.sounds.utilities
Sound is a powerful enhancement to any document. Internet Explorer 2.0 introduced another innovation for Web publications by enabling you to create documents with soundtracks. Internet Explorer directly support audio files in WAV, MIDI, AIFF, AIFF-C,
AU, and SND formats.
NOTE
Support for AIFF and AIFF-C sound files is a recent addition to Internet Explorer's growing support for document soundtracks. If you want to use AIFF and AIFF-C formats, you need Internet Explorer 3.0 or later versions.
You add a soundtrack to a document using the General tab of the Page Properties dialog box. As you see in Figure 11.2, there is a special area on this tab for background sounds.
Figure 11.2. Background sounds are specified in the Page Properties dialog box.
To create a soundtrack for a document, you need to enter the location of the source file as a relative or absolute URL. If you do not know the location of the source file, click the Browse button. This opens the dialog box shown in Figure 11.3. As with
most dialog boxes that let you browse for files, this dialog box has tabs for accessing audio files in the current web and audio files in other locations.
Figure 11.3. Browsing for a source file.
Because you are searching for audio files, you only see audio files with acceptable filename extensions in the Current FrontPage Web tab. These filename extensions include .wav, .rmi, .mid, .aif, .aifc, .aiff, .au, and .snd.
If the file you are looking for is not in the current web, click the Other Location tab. Using this tab, you can enter information for audio files that are on the local or remote file systems (see Figure 11.4).
Figure 11.4. Finding audio files on a local or remote file system.
TIP
When you add soundtracks to your documents, keep in mind my 14-second rule. In the increasingly robust multimedia environment the Web offers, graphics aren't the only thing that slow down page loading. Just as you wouldn't want to add 500KB worth of graphics to a page, you don't want to add a 500KB soundtrack to a page. The best background sounds are short in length (less than 60 seconds) and relatively small in file size (under 100KB).
By default, sound files play only once. You can change this default using the Loop property, specifying the number of times the audio file plays. You can set the loop to a specific value, such as 5. If you want the
soundtrack to continue to loop as long as the reader is on the page, you can set the value to indefinitely by selecting the Forever check box.
NOTE
If you are testing a sound that you do not want to loop, you can choose Refresh from your browser's View menu to play the sound again. Keep in mind that currently only Internet Explorer supports this extension.
Video is another explosive medium that Web publishers are experimenting with. Web users are just as fascinated with video as they are with sound and often seek out sites solely to find video clips. There are two basic types of video: digitized motion
video and animation. The ways to create animation and video are closely related. This is because animation is a series of still images, whereas video is a series of still representations of movement.
The idea of computer-generated animation is very simple. You draw a series of still images and play them back in near real time as if they were motion video. You can create many special effects using animation, such as bouncing a ball across the
screen, creating a spinning globe, or even making a tiny sun rise and set. The ways you can use animation in your Web publications are limited only by your imagination.
Generally, digitized motion video refers to video recorded on a video camera that is subsequently digitized for playback on a computer. Although early video productions were nothing more than digitized home videos, these productions attracted
tremendous interest from multimedia enthusiasts and Internet users around the world. The applications for using digitized video in your Web publications are limitless.
Another major advance in Web publishing is that you can now include video clips in your Web publications. Thanks to the development team at Microsoft, not only can you create publications with a digitized video sequence, but you can also control how
the video is played back and when. (See the section "Using Dynamic Sources to Create Inline Motion Video" to learn more about using internal video clips in your publications.)
Although browser support for video and animation sequences used within Web pages has only recently become possible, there is strong support for external video and animation sequences. Readers can access external video and animation sequences by
activating a hypertext link to the video file. You can easily create a link to a video file in the FrontPage Editor.
In the Editor, select the text or image that identifies the link and then either choose Hyperlink from the Edit menu or click the Create or Edit Hyperlink button. This opens the Create Hyperlink dialog box. In the Create Hyperlink dialog box, click
either the Current Web tab or the World Wide Web tab.
To create a link from the Current Web tab, enter the relative or page URL for the video file in the Page field. In Figure 11.5, the link points to a video file in MOV format called niagara_falls.mov. If you do not know the
URL, click the Browse button. From the Current Web dialog box, select the page or file you want to link to and then click the OK button.
Figure 11.5. Creating a link to a video file.
To create a link from the World Wide Web tab, select the HTTP protocol from the list of supported protocols. The Editor creates the protocol portion of the URL in the URL field. In the URL field, enter the absolute URL of the video file you want to
link, such as http://www.tvpress.com/hello.avi. When you are done, click OK.
When a reader clicks the link, the video file downloads to his or her computer. If a video player is available and configured for use in the reader's browser, the video file plays. If a video player is not available, the video file is stored on the
reader's hard disk for later playing. Browsers know which video player to launch based on the file type extension (.avi, .mov, .mpeg, and so forth) of the external sound
file referenced in your document. Consequently, you should always name your video files with an appropriate extension.
You should also let readers know the format and size of the video file. One way to do this is to simply insert the information into the text of your publication as follows:
Preview our newest Microsoft AVI movie, Cool Waves (4.5MB).
Before you add video or animation to your publications, there are many concepts you should consider. The most important matters you should think about are when and how to use video and animation in your publications.
Adding video to your publications is more complicated than adding other media. Video production merges concepts for still images, motion, and audio. When creating video, you need to understand multimedia concepts related to still images, moving
imageswhich are basically a series of still images that change in timeand audio. However, as you have seen in previous sections, adding multimedia to your publications is easy if you know the standards and related concepts.
Video signals are broadcast using a broadcast standard. NTSC is the broadcast standard in North America and Japan. PAL is the broadcast standard for most of Europe. Although there are other broadcast standards, such as SECAM used in France and
variations of PAL used in some European countries, NTSC and PAL are the broadcast standards in widest use.
When you create or incorporate a video sequence into your publication, you will probably use your local broadcast standard. However, consider where the audience for your publication resides. If you are in North America and your primary audience is in
Europe, you should create a PAL version of your video sequence. Switching between broadcast standards in a finished video can cause problems and affect the quality of the playback. To avoid problems, you should use video equipment that supports both NTSC
and PAL. However, specialized video equipment to convert your video sequence to other broadcast standards is available. There are also programs that enable you to display digitized PAL on an NTSC monitor and vice versa.
The key differences between PAL and NTSC are in the number of horizontal and vertical scan lines used and in how the images are interlaced for playback. NTSC-PAL and PAL-NTSC software converters take advantage of how the variance in horizontal and
vertical scan lines affect the physical screen size. Most of these converters simply convert the horizontal and vertical scan lines to a pixel size for the screen on which to display your images. The result is a screen of slightly different proportions
than what you are used to.
The NTSC standard specifies that broadcast quality video should be displayed at 60 fields per second. The images are interlaced, with the odd and even horizontal lines alternating during each pass. This means that actually only 30 distinct frames
appear each second. When you create real-time video or animation sequences for your publications, you also use the rate of 30 frames per second. If you are digitizing video sequences, you capture 30 video frames to create one second of motion video. If you
are creating an animation sequence, you use a series of 30 still images to create one second of animation.
Many Web publishers create video sequences by capturing them one frame at a time. The primary reason for this is that video digitizing equipment until recently was priced out of the reach of most small publishers. Thanks to recent advances in
technology, however, the prices for video digitizing equipment are falling fast. If you plan to create your own video sequences, check the current pricing. You might be surprised at how affordable the equipment is.
Creating 30 frames for a single second of motion video is a lot of work, which is why most digital video sequences are less than a minute in duration. A one-minute video sequence uses 1800 frames. Here's where you want to go back and review the
concepts covered earlier. Each video frame can eat up a lot of disk space, depending on the pixel bit depth and size of the image. A full-screen (640×480) 24-bit video frame uses as much as 1MB of disk space. Multiply that by 1800 and you will find
that each minute of motion video can gobble up as much as 1.8GB of disk space. To top it off, that's 1.8GB of disk space without audio. Add another 10MB per minute for stereo sound sampled at 44.1kHz.
Because video sequences can get so large, there are many techniques for reducing the resulting file size. The primary technique used is compression. When compressing video sequences, you select a compression ratio and a quality setting. A compression
ratio is the ratio at which video and accompanying audio, if any, is compressed. Some video formats let you compress files as much as 200:1. A 200:1 compression ratio means that your video sequence is squeezed into a space approximately 1/200th of its
original size. Although such a large compression ratio seems attractive, you cannot squeeze that much information out of a file without losing valuable data that directly affects the quality of the playback.
A quality setting, which is often used with compression, is a reality check describing the trade-off you want to make between the resulting file size and its quality during playback. A general range for quality setting is from 1 to 100. The higher the
quality setting, the larger the resulting file is and the better its playback quality. Quality settings can be confusing because a quality setting of 75 does not mean the resulting file has 75 percent of the information. The compression ratio describes how
much information to squeeze out of the file. The quality setting keeps the ratio of compression realistic when compared to your need for a quality playback.
Generally, your goal should be to select the highest compression ratio and lowest quality setting that provide playback quality you feel is acceptable. Try several combinations of compression ratios and quality settings. You should never use a quality
factor of 100, and you will probably not notice any loss of playback quality using a quality factor of 90.
Although compression is the major technique used to reduce the size of your video files and thus decrease the download time as well, compression alone is often not enough. Many video producers limit the width and height of the video to save disk space
and increase playback speed as well. A common size providing good playback speed with an acceptably sized playback window is 160×120. A video recorded at 160×120 is 16 times smaller than a video recorded at 640×480.
You can save disk space and reduce the download time in other ways as well. For the audio portion of the recording, you could use 8-bit mono instead of 16-bit stereo; 8-bit mono sound saves disk space and generally provides a fair quality playback. For
the video format, you could use an 8-bit pixel depth instead of a 24-bit pixel depth. Although you can use the 16.7 million colors offered by true 24-bit color to create sharp, high-quality videos, most computers can display only 256 colors anyway. A video
recorded in 256 colors is at least three times smaller than a video recorded in 16.7 million colors.
Although video technology is fairly new, it is advancing at an explosive pace. Video formats are also advancing. Autodesk's original flick format, FLI, has been widely used to create animation sequences, but is being replaced by the updated flick
format, FLC. Because animation and digitized video sequences both display a series of still images that change over time, many Web publishers use popular video formats to create animation sequences.
The most popular video formats are MPEG and QuickTime. MPEG offers advanced compression technology and quality playback. Apple's QuickTime format is a close second to MPEG, offering quality playback and basic compression techniques. Another format
working its way into the mainstream is Microsoft's AVI format. The AVI format offers features similar to those of QuickTime. The MPEG, QuickTime, and AVI formats offer quality solutions for video production and editing. As a result, the video format you
use will probably depend on the computer platform you prefer to work with and the video format that originated on that platform. The popular video formats and summary information for each format appear in Table 11.2.
Format | Extension | MIME Type | Compression |
AVI | .avi | video/x-msvideo | Yes |
MPEG-1 | .mpeg, .mpg, .mpe | video/mpeg | Yes |
MPEG-2 | .mpeg, .mpg, .mpe | video/mpeg | Yes |
QuickTime | .mov, .qt | video/quicktime | Yes |
The MPEG format is the world standard in video, yet it enjoys the most usage on UNIX systems. If you plan to use a UNIX platform, you probably want to use MPEG. Apple originally developed the QuickTime format. If you plan to use a
Macintosh, you probably want to use QuickTime. Microsoft originally developed the AVI format. If you plan to a Windows-based system, you probably want to use AVI. Although these guidelines are true most often, let's explore these formats to help you make a
more educated choice of video format for your publications.
TIP
Recently, Microsoft released a format called the ActiveMovie streaming format (ASF). This new video format is revolutionizing the way multimedia files are used on the Internet. With ASF, Web publishers can create Web documents with real-time video. To learn more about ASF, visit Microsoft's Interactive Media Home Page at http://www.microsoft.com/imedia/.
With the large installed base of Windows systems, it should come as no surprise that Microsoft's AVI format is gaining widespread popularity. AVI-formatted video files use the .avi extension. The AVI format is also referred
to as the Video for Windows format. Video for Windows is a video production software package sold by Microsoft. The software package includes a suite of tools for creating and editing video sequences, including VidCap, VidEdit, Media Player, BitEdit,
PalEdit, and WaveEdit.
Using VidCap, you can capture video in real time or step through the frames individually. The key to using VidCap in real time is to make sure your computer is fast enough to process a video frame and save it to disk before the next frame enters the
capture hardware. If the processing time exceeds the time it takes for the next frame to enter the capture hardware, you must use the step-frame capture mode.
VidCap processes the audio input with the frames as well. In real-time mode, the software captures the audio as it plays. In step-frame mode, the software captures the video frame and audio associated with the frame separately. VidCap accepts NTSC and
PAL video sources as inputs.
Using VidEdit, you can create and edit audio and video sequences. VidEdit displays video and audio segments as separate entities that you can edit in a variety of ways. You can cut out video frames and edit them individually with or without their
associated audio segment. You can also cut audio segments for editing and paste them into the video sequence in any order. In this way, you can create an entire new soundtrack for a video segment. With VidEdit, you can save video files in AVI format using
a variety of compression algorithms.
VidEdit plays FLC, FLI, DIB, and AVI video formats. You can use the Video for Windows Converter to convert Apple QuickTime to the AVI format. You can also edit your WAV files associated with a video sequence separately using WaveEdit.
Media Player enables you to play your video and audio sequences separately or together. Media Player plays videos in AVI format and audio in WAV format. Usually, the Media Player is included with Windows as an accessory. If it is not, you can obtain
runtime versions of the Media Player free.
BitEdit is a handy drawing tool that enables you to easily touch up your video files. Yet because BitEdit supports over a dozen popular image formats including GIF, you can use BitEdit to convert still images into AVI animation.
PalEdit is a handy editor for color palettes that enables you to perform many necessary tasks for color mapping. You can modify any color in a particular palette, modify the entire palette, reduce the number of colors in a palette, and even copy colors
from one palette to another.
TIP
If you are looking for information on the AVI format, visit Microsoft at http://www.microsoft.com/.
The MPEG format is the industry standard for video. The MPEG standard has several progressive levels, yet only two of these levels have been implemented. Although MPEG Level 1 became the world standard in video several years ago, MPEG Level 2 was
implemented in 1995. MPEG video files use the .mpeg, .mpg, or .mpe extension.
TIP
The best place on the Web to find information on MPEG is the Moving Pictures Expert Group (MPEG) Frequently Asked Questions (FAQ) page. At the MPEG FAQ page, you can find tools, detailed information on the MPEG standard, and information on making MPEG videos. The URL for the MPEG FAQ is http://www.crs4.it/HTML/LUIGI/MPEG/mpegfaq.html. An alternate source for the MPEG FAQ is http://www.lib.ox.ac.uk/internet/news/faq/by_category.mpeg-faq.html.
Another great site for technical information on MPEG is the MPEG resource list from the University of Minnesota's graphics and visualization lab. The list contains detailed examples of how to create MPEG video and then convert it to and from popular formats. You can find the MPEG resource list on the Web at http://www.arc.umn.edu/GVL/Software/mpeg.html.
MPEG Level 1 is the first and most versatile standard that the Moving Pictures Expert Group implemented. MPEG Level 1 video plays at roughly 30 frames per second. Although there are tricks to make the image window larger, MPEG-1 usually displays at a
resolution of 352×240 pixels or less. You can compress MPEG Level 1 files using either software or hardware encoders. Most Web publishers use MPEG-1 software encoders, which are very inexpensive. In fact, you can find free MPEG-1 software encoders on
the Internet.
Although MPEG-l software encoders are inexpensive and friendly, MPEG-1 hardware encoders are fast and efficient. The time savings that MPEG-1 hardware encoders offer is often a selling point in itself, especially if you plan to create multiple
video sequences or are on a tight time schedule. Generally, as you create a video sequence, you must experiment with many different compression and quality settings until you find the optimal setting. Each time you use a different setting, you must
compress the file and test the playback quality. An MPEG-1 hardware encoder's efficiency is another selling point. A more efficient compression routine can generally create a more compact and higher-quality video file.
Although the MPEG-1 standard is not associated with a single compression algorithm, MPEG-1 compression algorithms are generally more advanced than the algorithms used by AVI or QuickTime. Using MPEG-1 compression, you can compress video sequences up to
100:1. Many Web publishers use MPEG-1 compression because it produces no noticeable quality loss at compression ratios of 7:1 to 12:1. Even with compression ratios of up to 20:1, there is often little noticeable quality loss.
MPEG-1 players are available for all computer systems, including Amiga, Atari, Macintosh, DOS/Windows, and UNIX. Although early MPEG video players did not support audio tracks, most current MPEG players now support 16-bit stereo at sample rates up to
44.1kHz.
MPEG Level 2 is a high-quality video standard that the Moving Pictures Expert Group implemented in 1995. MPEG Level 2 video offers Web publishers true full-screen playback capability. Using MPEG-2, you can play 30 video frames per second at a
resolution of 720×480 pixels.
Although the MPEG-2 standard is not associated with a single compression algorithm, MPEG-2 compression algorithms are the most advanced video compression algorithms in use today. Using MPEG-2 compression, you can compress video sequences up to 200:1
with no noticeable quality loss at compression rates at high as 30:1.
The drawback to using MPEG-2 compression is that you need an MPEG-2 video encoder chip to compress the video sequence and an MPEG-2 decoder chip to decompress the video sequence. This means that in order to play your recording, users need a video board
with a MPEG-2 decoder chip. Although you can purchase video processing equipment with MPEG-2 encoder and decoder chips for around $2500, it will be some time before standard computer video boards include MPEG-2 decoder chips.
Apple's QuickTime format is one of the most popular formats on the Internetso popular, in fact, that the Netscape Navigator 3.0 includes direct support for it. QuickTime video files usually have the .mov or .qt extension. Macintosh systems have special software and hardware facilities for handling multimedia, and the QuickTime format takes full advantage of these facilities by separating video data into a resource fork and a data fork.
The resource fork contains information necessary for system resources such as the Macintosh's multimedia hardware. The data fork contains the actual bits and bytes.
To play QuickTime videos on other systems, the two data forks must be merged into a single data fork. The process of merging the data forks is called flattening; if ever someone tells you to flatten your QuickTime video, this is what they are talking
about. Although the process may sound complicated, there are tools you can use to flatten QuickTime videos at the press of a button.
Apple includes QuickTime players with current versions of System 7. If you own a Macintosh and do not have a QuickTime player, you can obtain one for free at the Apple QuickTime site highlighted in the section "Finding Video Resources on the
Internet" later in this chapter. You can also find free QuickTime players for Windows and UNIX X Windows systems.
TIP
Apple's QuickTime site is the place to find information on QuickTime. The site contains the latest players for the various systems QuickTime supports, lists of useful utilities, and even QuickTime videos. You find Apple's QuickTime site on the Web at http://quicktime.apple.com/.
Dozens of sites on the Web have video archives. The problem is that most of these sites are on servers maintained by universities, and sometimes when a site gets too popular, the site closes. To stay current with the changes, you might want to visit
the multimedia section at Yahoo:
http://www.yahoo.com/Computers_and_Internet/Multimedia/Movies/
If you own a Macintosh, visit this page at Yahoo:
http://www.yahoo.com/Computers_and_Internet/Multimedia/Video/Quicktime/Technical_Information/
Rob's Multimedia Lab, sponsored by the Association for Computing Machinery at University of Illinois Urbana/Champaign campus, is a comprehensive resource for all things related to multimedia. The front door to the site contains dozens
of links, but you can also go straight to the good stuff, which includes an image archive, a sound archive, and an MPEG movie archive:
Image archive
Sound archive
MPEG movie archive
Internet Explorer 2.0 takes the prize for developing one of the most innovative enhancements to the HTML specification. Using Internet Explorer's dynamic sources, you can incorporate motion video directly into your publication. Although the Internet
Explorer currently supports motion video only in Microsoft's AVI format, direct browser support for inline video is a major step toward true multimedia Web publications.
The development team at Microsoft considered very carefully how to incorporate video into publications and devised a way to incorporate video into existing pages without altering the way users without the Internet Explorer browser see the page. This
key concept for dynamic sources avoids leaving a gaping hole in the document where the video should be. To do this, the developers decided to extend the image tag and add an attribute called DYNSRC, which allows you to specify
a source image and a dynamic source video. Although users with an Internet Explorer-capable browser see the video, users without an Internet Explorer-capable browser see the image.
Adding dynamic sources to an existing image is easy. To start, select the image by clicking it. After you select the image, open the Image Properties dialog box by pressing Alt+Enter or selecting Image Properties from the Edit menu. Click the Video tab
so you can define properties for your dynamic source video. As you can see from Figure 11.6, some video properties are similar to properties used by background sounds.
Figure 11.6. Enter Video properties using the Video tab of the Image Properties dialog box.
TIP
Although it is recommended to define a source image and then a dynamic source video, FrontPage allows you to add dynamic source videos without defining a source image. To do this, select Video from the Edit menu. This opens the Video dialog box shown in Figure 11.7. After you specify a source file, close the dialog box by clicking the OK button. To define properties for the video, select the placeholder for the video by clicking it. Then, open the Image properties dialog box by pressing Alt+Enter or by selecting Image Properties from the Edit menu.
Figure 11.7. Finding video files.
The first time you use dynamic sources, you probably want to follow the default settings. When you do this, the only property you need to set is the Video Source. Enter the relative or absolute path to the video source in the input field provided. If
you don't know the URL path, click the Browse button. This opens the Video dialog box shown in Figure 11.7.
Using the Video dialog box, you can search for videos on local or remote file systems. Because AVI is the only format currently supported, the Current Web tab only lists files with the .avi extension. Similarly, when you
are browsing for files on the local file system, you are initially restricted to files with the .avi extension only. Although you can later change the file type to All, doing so is not very useful.
After you find the source file, click the OK button. Because the FrontPage Editor recognizes dynamic sources, your original image is replaced with a placeholder for videos. When you preview your page in the Internet Explorer, the video loads and plays
automatically. Browsers that do not support dynamic sources display the original source image. A sample page with a dynamic source is shown in Figure 11.8.
Figure 11.8. A Web page with a dynamic source video.
The FrontPage Editor allows you to manipulate the positioning and sizing of videos directly. Click once on the placeholder to manipulate the video in your page. On both ends and in the middle of a selected video are resizing points. If you move the
pointer to a resizing point and click and hold the left mouse button, you can resize the video by dragging the pointer. If you move the pointer to a different area of the video and click and hold the left mouse button, you can drag the video to a new
location on the page.
CAUTION
When you resize a video, you override the original size settings of the recorded video. This can cause distortion of the video image, especially in low-resolution recordings.
By default, user controls for the video do not appear. To add a basic set of user controls below the video frame, you select the Show Controls in Browser property. The basic controls include a
button that alternates between stop and play and a movable button that allows you to fast forward and reverse through a video (see Figure 11.9). Although there is only one set of controls at this time, Microsoft has plans to offer more control over the
style and functionality of the controls.
Figure 11.9. A video with controls.
Inline videos usually play only once. You can change this default using the Loop property, which specifies the number of times the video plays. You can set the loop to a specific value, such as 3. If you want the video to
continue to loop as long as the reader is on the page, you can select the Forever checkbox.
Using the Loop Delay property, you can specify how long the video waits before looping, in milliseconds. The video clip defined with the attributes shown in Figure 11.10 plays once and then waits two seconds before playing the video the second and
final time.
Figure 11.10. Looping the video.
Using properties in the Start area of the Video tab, you can set the video so it plays automatically. You can set this in either of two ways: the video plays automatically when the file opens or the video plays automatically when the user moves the
mouse over the video.
Internet Explorer creates an interesting way to use these values by enabling you to combine them. The video clip defined with the attributes shown in Figure 11.11 starts when the file finishes downloading and repeats whenever the user moves the mouse
cursor over the video.
Figure 11.11. Determining how the video starts.
Everywhere you look on the Web, you find Web publications that use multimedia. Web publishers use sound and video to enhance their pages and attract readers. You can use multimedia to convey your message in a way more powerful than text alone.
Multimedia can help sell your products and services. It can even show the rest of the world what your part of the world looks like.
Although images are a basic medium for your publications, you can also use sound and video. Both sound and video offer Web publishers a powerful way to express their ideas and reach readers. In fact, many Web users seek out sites that feature sound and
video.