You can easily use the RealSystem ad serving feature to deliver rich media ads in formats such as RealFlash and RealVideo. You simply modify your ad server to deliver a SMIL-based URL to a rich media ad clip hosted on a RealServer. The server-side #include tag in the target HTML page then expands to include the SMIL mark-up. RealServer's ad insertion plug-in parses the SMIL mark-up, extracting the rich media URL and placing it in the SMIL file that was originally requested.
|
|
Tip |
|---|
| Always account for the higher bandwidth requirements of rich media ads. Ensure that your target audience has sufficient bandwidth to receive both the ad and the requested file. |
#include tag into a URL to a rich media clip. The source URL and its hyperlink must follow SMIL mark-up conventions as described in RealSystem G2 Production Guide. The following is a simple example that turns an ad video into a link that, when clicked, opens the specified Web page:
<smil>
<a href="http://www.company.com" show="new"/>
<video src="rtsp://realserver.company.com/ads/ad1.rm">
</a>
</smil>
The <smil> and </smil> tags must be included so that RealServer recognizes the mark-up as SMIL. Because this is not a SMIL file meant to be played, the <body> and </body> tags that are normally required in SMIL are not needed.
#include tag that expands into the rich media URL. Because this HTML page simply carries SMIL mark-up, it does not need to have standard HTML components, such as a header section or <HTML> and </HTML> tags.
|
|
Additional Information |
|---|
| "Ad Target HTML Page". |
<RealAdInsert/> tag.
|
|
Additional Information |
|---|
| "General Ad Serving". |
<RealAdInsert/> tag in place of a source URL for the rich media ad. The following example plays two video clips in sequence. No layout is used. The first clip is the ad video:
<smil>
<body>
<seq>
<RealAdInsert/>
<video src="rtsp://realserver.company.com/video/video.rm"/>
</seq>
</body>
</smil>
|
|
Additional Information |
|---|
| "SMIL Files with Ad Content". |
In the example above, the video ad clip and requested video clip play in sequence. In this case, the viewer can skip the ad clip by choosing the second clip in the RealPlayer playlist. To disable the playlist, encapsulate the <seq> group in a <par> tag:
<smil>
<body>
<par><seq>
<RealAdInsert/>
<video src="rtsp://realserver.company.com/video/video.rm"/>
</seq>
</par></body>
</smil>
The examples above do not define SMIL playback regions. This makes the RealPlayer display window resize automatically for each clip. To prevent resizing, or to lay out clips that play together, define SMIL regions for the clips. Here's an example of one video region used for two clips played in sequence:
<smil>
<head>
<layout>
<root-layout width="240" height="180"/>
<region id="videoregion" width="240" height="180"/></layout>
</head>
<body>
<par>
<seq>
<RealAdInsertregion="videoregion"/>
<video src="rtsp://realserver.company.com/video/video.rm"region="videoregion"/>
</seq>
</par>
</body>
</smil>
For an example of two regions that lay out parallel clips, see the SMIL banner ad example in "SMIL Files with Ad Content". You could use a SMIL file like that one to lay out a video clip and a RealFlash banner ad, for example.
By using SMIL's clip timing commands, you can insert rich media ads within a requested clip. The following example inserts three rich media ads into a long video called news.rm. The effect is like a television program with commercial breaks:
<smil>
<head>
<layout>
<root-layout width="240" height="180"/>
<region id="videoregion" width="240" height="180"/>
</layout>
</head>
<body>
<par>
<seq>
<video src="news.rm" region="videoregion" clip-end="8.5min"/>
<RealAdInsert region="videoregion"/>
<video src="news.rm" region="videoregion" clip-begin="8.5min" clip-end="16.75min"/>
<RealAdInsert region="videoregion"/>
<video src="news.rm" region="videoregion" clip-begin="16.75min" clip-end="24.5min"/>
<RealAdInsert region="videoregion"/>
<video src="news.rm" region="videoregion" clip-begin="24.5min"/>
</seq>
</par>
</body>
</smil>
As shown above, the three ad clips and the main video clip, news.rm, are in a <seq> group. The news.rm video begins at its normal beginning and plays for 8.5 minutes. It then stops while the first ad plays. The news.rm clip then resumes where it left off, breaking at later intervals for the second and third ads. Because no timing elements are specified for the ads, they play from their normal beginnings to normal ends and may be any length.
Because RealServer's ad insertion plug-in replaces the <RealAdInsert/> tag with the contents of the target HTML file between its <smil> and </smil> tags, you can use your ad server to generate the requested file, not just the rich media URL. For example, your requested SMIL file could simply be a shell for a <RealAdInsert/> tag:
<smil>
<RealAdInsert/>
</smil>
Your target HTML file would then have an #include tag that expands into a full SMIL file, including a layout, the rich media ad URL, the requested clip URL, and any other SMIL mark-up.
This example is a rich media video ad that precedes the requested video clip.
Although the videos play sequentially, the SMIL source file lays out the two videos in two separate regions because the videos are different sizes:
<smil>
<head>
<meta name="title" content="Lead-in Video Ad followed by Video"/>
<meta name="author" content="RealNetworks, Inc."/>
<meta name="copyright" content="(c) 1999"/>
<layout>
<root-layout height="200" width="250" background-color="black"/>
<regionid="ad_region"left="37" top="30" height="132" width="176"/>
<regionid="video"left="5" top="10" width="240" height="180"/>
</layout>
</head>
<body>
<seq>
<!-- Lead in video ad -->
<RealAdInsert region="ad_region"/><!-- Requested content -->
<video src="rtsp://lizh.prognet.com:8800/g2video.rm"region="video"fill="freeze"/>
</seq>
</body>
</smil>
When a viewer requests this presentation, RealServer requests the target HTML file for the request URL's ad serving mount points. For a rich media ad, the target HTML file returns SMIL mark-up. Here's an example of SMIL mark-up returned to RealServer in the target HTML page:
<smil>
<!-- this is the ad -->
<video src="rtsp://lomotil-1.real.com/g2demos/Buick_150.rm"
region="ad_region" fill="remove"/>
</smil>
RealServer replaces the <RealAdInsert/> tag in the requested SMIL file with everything between the <smil> and </smil> tags of the returned target file.