What's New in QuickTime 4.1
| Previous | Chapter Contents | Chapter Top | Next |
In the example in Listing 1, a particular image starts by displaying a logo in JPEG format for five seconds. It then plays streaming video, which is a stored stream. This particular SMIL document does not specify the duration, which means that it will play it for as long as it is. Once it has finished, it will display the very same JPEG image at the end. This how you would wrap or bracket a stream with your logo.
Listing 1 A SMIL file displaying a JPEG image for five seconds, then playing a VOD stream to the end of the movie, followed by displaying a JPEG image without duration
<smil>
<head>
<layout>
<region id="j_VOD_j" width="160" height="120" />
</layout>
</head>
<body>
<seq>
<!--start with 160 x 120 jpeg from url, for duration of 5 secs-->
<img src="http://qtpartners.apple.com/ad/Images/image.jpg"
dur="5s"region="j_VOD_j"/>
<!--insert VOD movie, plays to end of movie-->
<video src="rtsp://qtsdemo.apple.com/ql41/codecs/sorenmodqt.mov"
region="j_VOD_j"/>
<!--then back to orig jpeg from url for duration of 5 seconds
(duration required for display)-->
<img src="http://qtpartners.apple.com/ad/Images/image.jpg"
region="j_VOD_j" dur="5s"/>
</seq>
</body>
</smil>
Simple sequences are very easy to create. In the body of the SMIL document, you explicitly state that this is a sequence by using the <seq> tag.
| Previous | Chapter Contents | Chapter Top | Next |